[Python-checkins] cpython (2.7): #13530: port to 2.7 branch (document what os.lseek returns).
georg.brandl
python-checkins at python.org
Tue Mar 11 10:29:13 CET 2014
http://hg.python.org/cpython/rev/168e40af4a20
changeset: 89580:168e40af4a20
branch: 2.7
parent: 89558:0ae254c11921
user: Georg Brandl <georg at python.org>
date: Tue Mar 11 10:28:56 2014 +0100
summary:
#13530: port to 2.7 branch (document what os.lseek returns).
files:
Doc/library/os.rst | 2 +-
Modules/posixmodule.c | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/Doc/library/os.rst b/Doc/library/os.rst
--- a/Doc/library/os.rst
+++ b/Doc/library/os.rst
@@ -744,7 +744,7 @@
by *how*: :const:`SEEK_SET` or ``0`` to set the position relative to the
beginning of the file; :const:`SEEK_CUR` or ``1`` to set it relative to the
current position; :const:`SEEK_END` or ``2`` to set it relative to the end of
- the file.
+ the file. Return the new cursor position in bytes, starting from the beginning.
Availability: Unix, Windows.
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -6667,7 +6667,8 @@
PyDoc_STRVAR(posix_lseek__doc__,
"lseek(fd, pos, how) -> newpos\n\n\
-Set the current position of a file descriptor.");
+Set the current position of a file descriptor.\n\
+Return the new cursor position in bytes, starting from the beginning.");
static PyObject *
posix_lseek(PyObject *self, PyObject *args)
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list