Show More
@@ -289,7 +289,9 b' def rename(src, dst):' | |||
|
289 | 289 | '''atomically rename file src to dst, replacing dst if it exists''' |
|
290 | 290 | try: |
|
291 | 291 | os.rename(src, dst) |
|
292 | except OSError: # FIXME: check err (EEXIST ?) | |
|
292 | except OSError, e: | |
|
293 | if e.errno != errno.EEXIST: | |
|
294 | raise | |
|
293 | 295 | |
|
294 | 296 | # On windows, rename to existing file is not allowed, so we |
|
295 | 297 | # must delete destination first. But if a file is open, unlink |
General Comments 0
You need to be logged in to leave comments.
Login now