On 09/07/2006, at 8:05 PM, [EMAIL PROTECTED] wrote:
Modified: httpd/mod_python/trunk/src/requestobject.c
URL: http://svn.apache.org/viewvc/httpd/mod_python/trunk/src/
requestobject.c?rev=420275&r1=420274&r2=420275&view=diff
======================================================================
========
--- httpd/mod_python/trunk/src/requestobject.c (original)
+++ httpd/mod_python/trunk/src/requestobject.c Sun Jul 9 03:05:30
2006
@@ -1139,6 +1139,7 @@
PyObject *line, *rlargs;
long sizehint = -1;
long size = 0;
+ long linesize;
if (! PyArg_ParseTuple(args, "|l", &sizehint))
return NULL;
@@ -1151,13 +1152,15 @@
return PyErr_NoMemory();
line = req_readline(self, rlargs);
- while (line && (PyString_Size(line)>0)) {
+ while (line && ((linesize=PyString_Size(line))>0)) {
PyList_Append(result, line);
- size += PyString_Size(line);
+ size += linesize;
if ((sizehint != -1) && (size >= size))
break;
+ Py_DECREF(line);
line = req_readline(self, args);
}
+ Py_XDECREF(line);
if (!line)
return NULL;
Did you forget to commit Doc/appendixc.tex bug fix list and version
files increment changes?
BTW, we still need to address:
http://issues.apache.org/jira/browse/MODPYTHON-179
in that function. :-)
Sorry for not helping much of late. Have got myself side tracked on
my own software.
Graham