##// END OF EJS Templates
with: use context manager for wlock in overridepurge
Bryan O'Sullivan -
r27825:4692571d default
parent child Browse files
Show More
@@ -1223,8 +1223,7 b' def overridepurge(orig, ui, repo, *dirs,'
1223 1223 orig(ui, repo, *dirs, **opts)
1224 1224 repo.status = oldstatus
1225 1225 def overriderollback(orig, ui, repo, **opts):
1226 wlock = repo.wlock()
1227 try:
1226 with repo.wlock():
1228 1227 before = repo.dirstate.parents()
1229 1228 orphans = set(f for f in repo.dirstate
1230 1229 if lfutil.isstandin(f) and repo.dirstate[f] != 'r')
@@ -1258,8 +1257,6 b' def overriderollback(orig, ui, repo, **o'
1258 1257 for lfile in orphans:
1259 1258 lfdirstate.drop(lfile)
1260 1259 lfdirstate.write()
1261 finally:
1262 wlock.release()
1263 1260 return result
1264 1261
1265 1262 def overridetransplant(orig, ui, repo, *revs, **opts):
General Comments 0
You need to be logged in to leave comments. Login now