]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
pyfec: make it compatible with Python 2.4 as well as Python 2.5
authorZooko O'Whielacronx <zooko@zooko.com>
Tue, 30 Jan 2007 22:58:45 +0000 (15:58 -0700)
committerZooko O'Whielacronx <zooko@zooko.com>
Tue, 30 Jan 2007 22:58:45 +0000 (15:58 -0700)
pyfec/README.txt
pyfec/fec/_fecmodule.c

index 88d0f7623a813f081b3aa7852497281117d95ee7..3285f090889c91e4fb3bfb11fac3ffeb7c398cee 100644 (file)
@@ -128,7 +128,8 @@ reading a file and encoding it piece by piece.
 
  * Dependencies
 
-A C compiler is required.  For the Python API, Python version 2.5 is required.
+A C compiler is required.  For the Python API, we have tested it with Python
+v2.4 and v2.5.
 
 
  * Performance Measurements
index 70c8b82cdff6387640208b9a44e04c77e453221c..e62e85c5541acaea36902874b3ba7d3552a8b045 100644 (file)
 #include <Python.h>
 #include <structmember.h>
 
+#if (PY_VERSION_HEX < 0x02050000)
+typedef int Py_ssize_t;
+#endif
+
 #include "fec.h"
 
 static PyObject *py_fec_error;