]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-42620: Improve socket.getsockname doc string (GH-23742)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Wed, 23 Dec 2020 07:44:00 +0000 (23:44 -0800)
committerGitHub <noreply@github.com>
Wed, 23 Dec 2020 07:44:00 +0000 (23:44 -0800)
Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit cf3565ca9a7ed0f7decd000e41fa3de400986e4d)

Co-authored-by: Christian Heimes <christian@python.org>
Modules/socketmodule.c

index 5dc5f4e0d397b4e0c91beb1c6af6f8c73ca240c5..3e65dc027a38ca2da5f3ba5e2cda746303fa6868 100644 (file)
@@ -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 :-( */