[Python-checkins] cpython: Issue #13300: Fix IDLE Restart Shell command failure introduced by

ned.deily python-checkins at python.org
Sun Nov 6 06:37:56 CET 2011


http://hg.python.org/cpython/rev/ce483d696c06
changeset:   73399:ce483d696c06
user:        Ned Deily <nad at acm.org>
date:        Sat Nov 05 22:36:44 2011 -0700
summary:
  Issue #13300: Fix IDLE Restart Shell command failure introduced by
3a5a0943b201.  Do not close listening socket on subprocess restart.

files:
  Lib/idlelib/PyShell.py |  4 ++++
  Lib/idlelib/rpc.py     |  4 ----
  2 files changed, 4 insertions(+), 4 deletions(-)


diff --git a/Lib/idlelib/PyShell.py b/Lib/idlelib/PyShell.py
--- a/Lib/idlelib/PyShell.py
+++ b/Lib/idlelib/PyShell.py
@@ -460,6 +460,10 @@
 
     def kill_subprocess(self):
         try:
+            self.rpcclt.listening_sock.close()
+        except AttributeError:  # no socket
+            pass
+        try:
             self.rpcclt.close()
         except AttributeError:  # no socket
             pass
diff --git a/Lib/idlelib/rpc.py b/Lib/idlelib/rpc.py
--- a/Lib/idlelib/rpc.py
+++ b/Lib/idlelib/rpc.py
@@ -534,10 +534,6 @@
     def get_remote_proxy(self, oid):
         return RPCProxy(self, oid)
 
-    def close(self):
-        self.listening_sock.close()
-        SocketIO.close(self)
-
 class RPCProxy(object):
 
     __methods = None

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list