diff options
author | Georg Brandl <georg@python.org> | 2014-03-11 09:28:56 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2014-03-11 09:28:56 (GMT) |
commit | 6d07641fce428abf826a0d90ce0aeaf0e3450587 (patch) | |
tree | 7cdfda09cd9a662dd1a70fa6e40b14785e5cdf65 | |
parent | 418b1eab910cd6c8a88f72b145c04e0554d5306d (diff) | |
download | cpython-6d07641fce428abf826a0d90ce0aeaf0e3450587.zip cpython-6d07641fce428abf826a0d90ce0aeaf0e3450587.tar.gz cpython-6d07641fce428abf826a0d90ce0aeaf0e3450587.tar.bz2 |
#13530: port to 2.7 branch (document what os.lseek returns).
-rw-r--r-- | Doc/library/os.rst | 2 | ||||
-rw-r--r-- | Modules/posixmodule.c | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/Doc/library/os.rst b/Doc/library/os.rst index 679cedb..fe03096 100644 --- a/Doc/library/os.rst +++ b/Doc/library/os.rst @@ -744,7 +744,7 @@ as internal buffering of data. 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 index c1b300a..21a6cef 100644 --- a/Modules/posixmodule.c +++ b/Modules/posixmodule.c @@ -6667,7 +6667,8 @@ posix_dup2(PyObject *self, PyObject *args) 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) |