mirror of
https://github.com/borgbackup/borg.git
synced 2025-03-04 10:39:50 +00:00
use os.replace not os.rename
This commit is contained in:
parent
804867d3ad
commit
91104674e7
1 changed files with 1 additions and 1 deletions
|
@ -139,7 +139,7 @@ class ExclusiveLock:
|
|||
timer = TimeoutTimer(timeout, sleep).start()
|
||||
while True:
|
||||
try:
|
||||
os.rename(temp_path, self.path)
|
||||
os.replace(temp_path, self.path)
|
||||
except OSError: # already locked
|
||||
if self.by_me():
|
||||
return self
|
||||
|
|
Loading…
Add table
Reference in a new issue