From: Giampaolo Rodola' Date: Wed, 10 Apr 2013 13:49:47 +0000 (+0200) Subject: Fix issue #17675: make socket repr() provide local and remote addresses (if any). X-Git-Tag: v3.4.0a1~995 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=50331cbf0894bd18d8c89669297776153036bbbb;p=python Fix issue #17675: make socket repr() provide local and remote addresses (if any). --- diff --git a/Lib/socket.py b/Lib/socket.py index da0c39a8ae..96f8ed0c7f 100644 --- a/Lib/socket.py +++ b/Lib/socket.py @@ -103,13 +103,32 @@ class socket(_socket.socket): self.close() def __repr__(self): - """Wrap __repr__() to reveal the real class name.""" - s = _socket.socket.__repr__(self) - if s.startswith("