summaryrefslogtreecommitdiffstats
path: root/Doc/library/socket.rst
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2021-08-26 19:54:52 (GMT)
committerGitHub <noreply@github.com>2021-08-26 19:54:52 (GMT)
commit719af92e108ea3b31729cb09077673b8f13905d2 (patch)
treeadcf3ecba9349a802b86dd7bfe5d5f8d7cddec09 /Doc/library/socket.rst
parent9a79242567d79f42ad1a953cce2b1c4a94df23ea (diff)
downloadcpython-719af92e108ea3b31729cb09077673b8f13905d2.zip
cpython-719af92e108ea3b31729cb09077673b8f13905d2.tar.gz
cpython-719af92e108ea3b31729cb09077673b8f13905d2.tar.bz2
bpo-40635: Fix getfqdn() docstring and docs (GH-27971)
Co-authored-by: Ɓukasz Langa <lukasz@langa.pl> (cherry picked from commit fdcb675eed47b1f6054fae381af4388b16a6fff4) Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
Diffstat (limited to 'Doc/library/socket.rst')
-rwxr-xr-xDoc/library/socket.rst5
1 files changed, 3 insertions, 2 deletions
diff --git a/Doc/library/socket.rst b/Doc/library/socket.rst
index e1db1b5..1b6dc4d 100755
--- a/Doc/library/socket.rst
+++ b/Doc/library/socket.rst
@@ -808,8 +808,9 @@ The :mod:`socket` module also offers various network-related services:
it is interpreted as the local host. To find the fully qualified name, the
hostname returned by :func:`gethostbyaddr` is checked, followed by aliases for the
host, if available. The first name which includes a period is selected. In
- case no fully qualified domain name is available, the hostname as returned by
- :func:`gethostname` is returned.
+ case no fully qualified domain name is available and *name* was provided,
+ it is returned unchanged. If *name* was empty or equal to ``'0.0.0.0'``,
+ the hostname from :func:`gethostname` is returned.
.. function:: gethostbyname(hostname)