##// END OF EJS Templates
dirstate: use tryunlink
Ryan McElroy -
r31547:ddadb6b0 default
parent child Browse files
Show More
@@ -1262,8 +1262,7 b' class dirstate(object):'
1262
1262
1263 backupname = prefix + self._filename + suffix
1263 backupname = prefix + self._filename + suffix
1264 assert backupname != filename
1264 assert backupname != filename
1265 if self._opener.exists(backupname):
1265 self._opener.tryunlink(backupname)
1266 self._opener.unlink(backupname)
1267 # hardlink backup is okay because _writedirstate is always called
1266 # hardlink backup is okay because _writedirstate is always called
1268 # with an "atomictemp=True" file.
1267 # with an "atomictemp=True" file.
1269 util.copyfile(self._opener.join(filename),
1268 util.copyfile(self._opener.join(filename),
General Comments 0
You need to be logged in to leave comments. Login now