summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBob Ippolito <bob@redivi.com>2011-04-19 12:58:49 -0700
committerBob Ippolito <bob@redivi.com>2011-04-19 12:58:49 -0700
commitf99c5f56e119f89b69867a569af38faa7435e30c (patch)
tree16c81982ed988e4bfe1ef6cd20ee5b9ef13c98ee
parent729d79e8581bed4188edab4d4910d858e2f0b214 (diff)
downloadsimplejson-f99c5f56e119f89b69867a569af38faa7435e30c.tar.gz
https://github.com/simplejson/simplejson/issues/5
-rw-r--r--CHANGES.txt5
-rw-r--r--simplejson/_speedups.c3
2 files changed, 8 insertions, 0 deletions
diff --git a/CHANGES.txt b/CHANGES.txt
index 6f09d2c..30d81e5 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,3 +1,8 @@
+Version 2.1.6 released 2011-XX-XX
+
+* Fix compatibility with Python 2.5
+ https://github.com/simplejson/simplejson/issues/5
+
Version 2.1.5 released 2011-04-17
* Built sdist tarball with setuptools_git installed. Argh.
diff --git a/simplejson/_speedups.c b/simplejson/_speedups.c
index e43ae7c..1deea40 100644
--- a/simplejson/_speedups.c
+++ b/simplejson/_speedups.c
@@ -18,6 +18,9 @@ json_PyOS_string_to_double(const char *s, char **endptr, PyObject *overflow_exce
#if PY_VERSION_HEX < 0x02060000 && !defined(Py_TYPE)
#define Py_TYPE(ob) (((PyObject*)(ob))->ob_type)
#endif
+#if PY_VERSION_HEX < 0x02060000 && !defined(Py_SIZE)
+#define Py_SIZE(ob) (((PyVarObject*)(ob))->ob_size)
+#endif
#if PY_VERSION_HEX < 0x02050000 && !defined(PY_SSIZE_T_MIN)
typedef int Py_ssize_t;
#define PY_SSIZE_T_MAX INT_MAX