summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2020-12-23 07:44:00 (GMT)
committerGitHub <noreply@github.com>2020-12-23 07:44:00 (GMT)
commitb20494618c6ac6ebcd354e0b16a6645fe47acbee (patch)
treeaa8c54b96746045951105ed453405a3231ca0e11
parent02349e2dc9d93202c658ae383b2de2e36b2366f8 (diff)
downloadcpython-b20494618c6ac6ebcd354e0b16a6645fe47acbee.zip
cpython-b20494618c6ac6ebcd354e0b16a6645fe47acbee.tar.gz
cpython-b20494618c6ac6ebcd354e0b16a6645fe47acbee.tar.bz2
bpo-42620: Improve socket.getsockname doc string (GH-23742)
Signed-off-by: Christian Heimes <christian@python.org> (cherry picked from commit cf3565ca9a7ed0f7decd000e41fa3de400986e4d) Co-authored-by: Christian Heimes <christian@python.org>
-rw-r--r--Modules/socketmodule.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c
index 5dc5f4e..3e65dc0 100644
--- a/Modules/socketmodule.c
+++ b/Modules/socketmodule.c
@@ -3324,8 +3324,9 @@ sock_getsockname(PySocketSockObject *s, PyObject *Py_UNUSED(ignored))
PyDoc_STRVAR(getsockname_doc,
"getsockname() -> address info\n\
\n\
-Return the address of the local endpoint. For IP sockets, the address\n\
-info is a pair (hostaddr, port).");
+Return the address of the local endpoint. The format depends on the\n\
+address family. For IPv4 sockets, the address info is a pair\n\
+(hostaddr, port).");
#ifdef HAVE_GETPEERNAME /* Cray APP doesn't have this :-( */