]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Use _RPCFile.write properly.
authorMartin v. Löwis <martin@v.loewis.de>
Wed, 11 Jul 2012 07:17:15 +0000 (09:17 +0200)
committerMartin v. Löwis <martin@v.loewis.de>
Wed, 11 Jul 2012 07:17:15 +0000 (09:17 +0200)
Lib/idlelib/run.py

index 43a7f659b60b4f7e1b9aef85564b622120adb324..cbfa8f86ea56b3ba513b6cc7465e86c1371cf001 100644 (file)
@@ -255,8 +255,8 @@ class _RPCFile(io.TextIOBase):
         super.__setattr__(self, 'rpc', rpc)
 
     def __getattribute__(self, name):
-        # When accessing the 'rpc' attribute, use ours
-        if name == 'rpc':
+        # When accessing the 'rpc' attribute, or 'write', use ours
+        if name in ('rpc', 'write'):
             return io.TextIOBase.__getattribute__(self, name)
         # Else only look into the remote object only
         return getattr(self.rpc, name)