comparison mercurial/bundlerepo.py @ 21562:dbf292f65b09

bundlerepo: update unlink in getremotechanges to use vfs As per WindowsUTF8 plan, unlink from getremotechanges is updated to use vfs in this change.
author Chinmay Joshi <c@chinmayjoshi.com>
date Tue, 27 May 2014 21:56:03 +0530
parents 4d9d490d7bbe
children c08a22bfa16e
comparison
equal deleted inserted replaced
21561:f1bcc33a5c52 21562:dbf292f65b09
350 force=force) 350 force=force)
351 common, incoming, rheads = tmp 351 common, incoming, rheads = tmp
352 if not incoming: 352 if not incoming:
353 try: 353 try:
354 if bundlename: 354 if bundlename:
355 os.unlink(bundlename) 355 repo.vfs.unlink(bundlename)
356 except OSError: 356 except OSError:
357 pass 357 pass
358 return repo, [], other.close 358 return repo, [], other.close
359 359
360 bundle = None 360 bundle = None
392 392
393 def cleanup(): 393 def cleanup():
394 if bundlerepo: 394 if bundlerepo:
395 bundlerepo.close() 395 bundlerepo.close()
396 if bundle: 396 if bundle:
397 os.unlink(bundle) 397 repo.vfs.unlink(bundle)
398 other.close() 398 other.close()
399 399
400 return (localrepo, csets, cleanup) 400 return (localrepo, csets, cleanup)