Closed GoogleCodeExporter closed 8 years ago
What version of Python are you using?
Original comment by Graham.Dumpleton@gmail.com
on 27 Dec 2011 at 11:15
Also provide the exact error message you are currently getting in any exception
raised.
Original comment by Graham.Dumpleton@gmail.com
on 27 Dec 2011 at 11:17
The correct fix is:
--- a/mod_wsgi/mod_wsgi.c Tue Nov 29 16:30:24 2011 +1100
+++ b/mod_wsgi/mod_wsgi.c Tue Dec 27 22:25:23 2011 +1100
@@ -1515,8 +1515,14 @@
while ((item = PyIter_Next(iterator))) {
PyObject *result = NULL;
-
- result = Log_write(self, item);
+ PyObject *args = NULL;
+
+ args = PyTuple_Pack(1, item);
+
+ result = Log_write(self, args);
+
+ Py_DECREF(args);
+ Py_DECREF(item);
if (!result) {
Py_DECREF(iterator);
There was also a memory leak in there as object returned from iterator didn't
have its reference count decremented.
Original comment by Graham.Dumpleton@gmail.com
on 27 Dec 2011 at 11:27
This change was already made in mod_wsgi trunk for 4.0.
Original comment by Graham.Dumpleton@gmail.com
on 19 Mar 2012 at 9:47
Original comment by Graham.Dumpleton@gmail.com
on 28 Mar 2013 at 6:30
Original issue reported on code.google.com by
kofreestyler
on 27 Dec 2011 at 11:09