Skip to content

Commit 388c945

Browse files
committed
#12725: fix working. Patch by Ben Hayden.
1 parent 3abb372 commit 388c945

3 files changed

Lines changed: 7 additions & 6 deletions

File tree

Doc/ACKS.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ docs@python.org), and we'll be glad to correct the problem.
7979
* Travis B. Hartwell
8080
* Tim Hatch
8181
* Janko Hauser
82+
* Ben Hayden
8283
* Thomas Heller
8384
* Bernhard Herzog
8485
* Magnus L. Hetland

Doc/library/socket.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -513,14 +513,14 @@ The module :mod:`socket` exports the following constants and functions:
513513

514514
.. function:: getdefaulttimeout()
515515

516-
Return the default timeout in floating seconds for new socket objects. A value
516+
Return the default timeout in seconds (float) for new socket objects. A value
517517
of ``None`` indicates that new socket objects have no timeout. When the socket
518518
module is first imported, the default is ``None``.
519519

520520

521521
.. function:: setdefaulttimeout(timeout)
522522

523-
Set the default timeout in floating seconds for new socket objects. When
523+
Set the default timeout in seconds (float) for new socket objects. When
524524
the socket module is first imported, the default is ``None``. See
525525
:meth:`~socket.settimeout` for possible values and their respective
526526
meanings.
@@ -632,7 +632,7 @@ correspond to Unix system calls applicable to sockets.
632632

633633
.. method:: socket.gettimeout()
634634

635-
Return the timeout in floating seconds associated with socket operations,
635+
Return the timeout in seconds (float) associated with socket operations,
636636
or ``None`` if no timeout is set. This reflects the last call to
637637
:meth:`setblocking` or :meth:`settimeout`.
638638

Modules/socketmodule.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1808,7 +1808,7 @@ sock_gettimeout(PySocketSockObject *s)
18081808
PyDoc_STRVAR(gettimeout_doc,
18091809
"gettimeout() -> timeout\n\
18101810
\n\
1811-
Returns the timeout in floating seconds associated with socket \n\
1811+
Returns the timeout in seconds (float) associated with socket \n\
18121812
operations. A timeout of None indicates that timeouts on socket \n\
18131813
operations are disabled.");
18141814

@@ -4201,7 +4201,7 @@ socket_getdefaulttimeout(PyObject *self)
42014201
PyDoc_STRVAR(getdefaulttimeout_doc,
42024202
"getdefaulttimeout() -> timeout\n\
42034203
\n\
4204-
Returns the default timeout in floating seconds for new socket objects.\n\
4204+
Returns the default timeout in seconds (float) for new socket objects.\n\
42054205
A value of None indicates that new socket objects have no timeout.\n\
42064206
When the socket module is first imported, the default is None.");
42074207

@@ -4231,7 +4231,7 @@ socket_setdefaulttimeout(PyObject *self, PyObject *arg)
42314231
PyDoc_STRVAR(setdefaulttimeout_doc,
42324232
"setdefaulttimeout(timeout)\n\
42334233
\n\
4234-
Set the default timeout in floating seconds for new socket objects.\n\
4234+
Set the default timeout in seconds (float) for new socket objects.\n\
42354235
A value of None indicates that new socket objects have no timeout.\n\
42364236
When the socket module is first imported, the default is None.");
42374237

0 commit comments

Comments
 (0)