[Python-bugs-list] [ python-Bugs-559117 ] HTTPSConnection memory leakage

noreply@sourceforge.net noreply@sourceforge.net
Wed, 22 May 2002 04:09:54 -0700


Bugs item #559117, was opened at 2002-05-22 13:09
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=559117&group_id=5470

Category: Python Library
Group: Python 2.1.2
Status: Open
Resolution: None
Priority: 5
Submitted By: Paolo Andreetto (pandreetto)
Assigned to: Nobody/Anonymous (nobody)
Summary: HTTPSConnection memory leakage

Initial Comment:
I've tried this test script:

import time,httplib,gc

gc.set_debug(gc.DEBUG_STATS)

while 1:
	conn=httplib.HTTPSConnection('<myhostip>')
	conn.connect()
	conn.request('GET', '/index.html')
	res=conn.getresponse()
	conn.close()
	time.sleep(1)
	print gc.collect()

and I've seen that a memory leakage occurs. The process
requires 4Kbytes every 10 seconds. The output of
garbage collector shows that at the end of each cycle a
new object is contained into last generation.
I've tried also to remove from the script both the
conn.request and the conn.getresponse but nothing has
changed; perhaps the problem is in the connect() method.
All tests run on linux (debian distribution, sid
version for i386) with kernel 2.4.18 and python 2.1.3.
The web server is apache with mod-ssl on redhat 7.2.


----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=559117&group_id=5470