diff options
| author | Tim Peters <tim.peters@gmail.com> | 2002-12-23 16:26:15 +0000 |
|---|---|---|
| committer | Tim Peters <tim.peters@gmail.com> | 2002-12-23 16:26:15 +0000 |
| commit | 7adc32ffa4215a398b38a6c38987d1fbf5a9ac05 (patch) | |
| tree | 3d4baaf11da234be38ceb1cd7413aac5538729ac /Lib/socket.py | |
| parent | cc80e80c8af1114db77cffc1e82c1631b6e01e5b (diff) | |
| download | cpython-git-7adc32ffa4215a398b38a6c38987d1fbf5a9ac05.tar.gz | |
Backporting a small part of the socket.py changes from 2.3: get rid
of the socket wrapper __del__ method. It isn't needed, and it prevents
cyclic structures containing socket objects (primarily on Windows, where
the wrapper is used) from getting garbage-collected. People running
ZEO tests in Zope under Windows are acutely aware of this, as the
test driver prints an ever-growing gc.garbage list after each test.
Diffstat (limited to 'Lib/socket.py')
| -rw-r--r-- | Lib/socket.py | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/Lib/socket.py b/Lib/socket.py index e298f51f13..5fac123c98 100644 --- a/Lib/socket.py +++ b/Lib/socket.py @@ -140,9 +140,6 @@ class _socketobject: # Avoid referencing globals here self._sock = self.__class__._closedsocket() - def __del__(self): - self.close() - def accept(self): sock, addr = self._sock.accept() return _socketobject(sock), addr |
