summaryrefslogtreecommitdiff
path: root/Lib/lib2to3/main.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/lib2to3/main.py')
-rw-r--r--Lib/lib2to3/main.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/lib2to3/main.py b/Lib/lib2to3/main.py
index f9cc18b5d3..93bae9021a 100644
--- a/Lib/lib2to3/main.py
+++ b/Lib/lib2to3/main.py
@@ -90,11 +90,11 @@ class StdoutRefactoringTool(refactor.MultiprocessRefactoringTool):
if os.path.lexists(backup):
try:
os.remove(backup)
- except os.error as err:
+ except OSError as err:
self.log_message("Can't remove backup %s", backup)
try:
os.rename(filename, backup)
- except os.error as err:
+ except OSError as err:
self.log_message("Can't rename %s to %s", filename, backup)
# Actually write the new file
write = super(StdoutRefactoringTool, self).write_file