summaryrefslogtreecommitdiffstats
path: root/Lib/logging
diff options
context:
space:
mode:
authorAndrew Svetlov <andrew.svetlov@gmail.com>2012-12-25 14:47:37 (GMT)
committerAndrew Svetlov <andrew.svetlov@gmail.com>2012-12-25 14:47:37 (GMT)
commitf7a17b48d748e1835bcf9df86fb7fb318bb020f8 (patch)
tree403d91c57f72d6e538ce09a8037bd658bc619760 /Lib/logging
parent16bdd4120d8452e8e04b124bcdd116608c5166b0 (diff)
downloadcpython-f7a17b48d748e1835bcf9df86fb7fb318bb020f8.zip
cpython-f7a17b48d748e1835bcf9df86fb7fb318bb020f8.tar.gz
cpython-f7a17b48d748e1835bcf9df86fb7fb318bb020f8.tar.bz2
Replace IOError with OSError (#16715)
Diffstat (limited to 'Lib/logging')
-rw-r--r--Lib/logging/__init__.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/logging/__init__.py b/Lib/logging/__init__.py
index 6f8b4fa..b8e7b37 100644
--- a/Lib/logging/__init__.py
+++ b/Lib/logging/__init__.py
@@ -896,7 +896,7 @@ class Handler(Filterer):
# couldn't find the right stack frame, for some reason
sys.stderr.write('Logged from file %s, line %s\n' % (
record.filename, record.lineno))
- except IOError: #pragma: no cover
+ except OSError: #pragma: no cover
pass # see issue 5971
finally:
del t, v, tb
@@ -1838,7 +1838,7 @@ def shutdown(handlerList=_handlerList):
h.acquire()
h.flush()
h.close()
- except (IOError, ValueError):
+ except (OSError, ValueError):
# Ignore errors which might be caused
# because handlers have been closed but
# references to them are still around at