]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Update fcntl doc: replace IOError with OSError
authorVictor Stinner <victor.stinner@gmail.com>
Sat, 9 Apr 2016 09:32:58 +0000 (11:32 +0200)
committerVictor Stinner <victor.stinner@gmail.com>
Sat, 9 Apr 2016 09:32:58 +0000 (11:32 +0200)
Issue #26716. IOError is a deprecated alias to OSError since Python 3.3.

Doc/library/fcntl.rst
Modules/fcntlmodule.c

index f8bb8340ea91918ce150e6af2ed37a94f8092acc..22f0f25eea7c68e4725135c2ff1a5fadd02b31fc 100644 (file)
@@ -83,7 +83,7 @@ The module defines the following functions:
    buffer 1024 bytes long which is then passed to :func:`ioctl` and copied back
    into the supplied buffer.
 
-   If the :c:func:`ioctl` fails, an :exc:`IOError` exception is raised.
+   If the :c:func:`ioctl` fails, an :exc:`OSError` exception is raised.
 
    An example::
 
@@ -106,7 +106,7 @@ The module defines the following functions:
    :manpage:`flock(2)` for details.  (On some systems, this function is emulated
    using :c:func:`fcntl`.)
 
-   If the :c:func:`flock` fails, an :exc:`IOError` exception is raised.
+   If the :c:func:`flock` fails, an :exc:`OSError` exception is raised.
 
 
 .. function:: lockf(fd, cmd, len=0, start=0, whence=0)
index 97ff07c12e98362948f1c3e523f97e4eef3e4392..e61c93095cc64ac14b757053068b2ece6f71b620 100644 (file)
@@ -344,7 +344,7 @@ of the following values:
 
 When operation is LOCK_SH or LOCK_EX, it can also be bitwise ORed with
 LOCK_NB to avoid blocking on lock acquisition.  If LOCK_NB is used and the
-lock cannot be acquired, an IOError will be raised and the exception will
+lock cannot be acquired, an OSError will be raised and the exception will
 have an errno attribute set to EACCES or EAGAIN (depending on the operating
 system -- for portability, check for either value).