[issue1092502] Memory leak in socket.py on Mac OS X

2008-04-29 Thread Mark Hammond

Mark Hammond [EMAIL PROTECTED] added the comment:

FYI, #2632 is tracking a regression caused by this change.

--
nosy: +mhammond

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1092502] Memory leak in socket.py on Mac OS X

2008-04-15 Thread Gregory P. Smith

Changes by Gregory P. Smith [EMAIL PROTECTED]:


--
nosy: +gregory.p.smith

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1092502] Memory leak in socket.py on Mac OS X

2008-04-14 Thread Ralf Schmitt

Ralf Schmitt [EMAIL PROTECTED] added the comment:

I think this should be fixed somewhere in the c code. people calling
sock.recv which a large recv size will also trigger this error.
this fix is wrong. the fixed code reads one byte at a time.
see:
http://mail.python.org/pipermail/python-dev/2008-April/078613.html

--
nosy: +schmir

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1092502] Memory leak in socket.py on Mac OS X

2008-04-14 Thread A.M. Kuchling

A.M. Kuchling [EMAIL PROTECTED] added the comment:

Note that _rbufsize is only set to 1 if the _fileobject's bufsize is set
to 0.  So perhaps the bug is that some library is turning off buffering
when it shouldn't.

I don't see how you would fix this in the C code, other than manually
doing two separate mallocs and copying the data, which would unfairly
penalize platforms with smarter malloc() implementations.  What sort of
fix would you suggest?

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1092502] Memory leak in socket.py on Mac OS X

2008-04-14 Thread Ralf Schmitt

Ralf Schmitt [EMAIL PROTECTED] added the comment:

Well, I think the right thing to do is limit the maximal size to be read
inside the c function (just to make it impossible to pass around large
values). This is basically the same fix just at another place in the code.


http://twistedmatrix.com/trac/ticket/1079 describes the same problem
(but with 64 k read requests: it can even leak with small requests).
The fix there was to really copy those strings around into a StringIO
object.

Note that the code does not read byte by byte when passing in no size
argument. Instead it read recv_size bytes:

if self._rbufsize = 1:
recv_size = self.default_bufsize
else:
recv_size = self._rbufsize

This seems clearly wrong to me.

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1092502] Memory leak in socket.py on Mac OS X

2008-04-14 Thread Ralf Schmitt

Ralf Schmitt [EMAIL PROTECTED] added the comment:

that is it seems wrong that it uses 1 byte when a size is given, and
recv_size when size is not given.

By the way I think if you ask for 4096 bytes and the buffering is set to
2048 bytes it should still try to read the full 4096 bytes.
The number of bytes it tries to read however. should be limited by
whatever the system maximally returns.

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1092502] Memory leak in socket.py on Mac OS X

2008-03-07 Thread vila

Changes by vila:


--
nosy: +vila

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1092502] Memory leak in socket.py on Mac OS X

2008-02-23 Thread A.M. Kuchling

A.M. Kuchling added the comment:

Andreas Lauer's suggested fix is correct.  Applied to 2.6 trunk in rev.
61008 and to 2.5-maint in rev. 61009.

--
nosy: +akuchling
resolution: out of date - fixed

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1092502] Memory leak in socket.py on Mac OS X

2008-01-20 Thread Martey Dodoo

Martey Dodoo added the comment:

Just wanted to note that the good people of comp.lang.python helped me
figure out that the issue is actually
http://bugs.python.org/issue1389051, in case anyone in similar straits
ended up here.

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1092502] Memory leak in socket.py on Mac OS X 10.3

2008-01-05 Thread Christian Heimes

Christian Heimes added the comment:

Probably outdated

I haven't heard or seen any such problems in the past two years.

--
nosy: +tiran
resolution:  - out of date
status: open - closed

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1092502
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com