mercurial/transaction.py
changeset 7334 618140c75d8d
parent 6441 c9b8f2820bc0
child 7335 866d2715aff5
equal deleted inserted replaced
7333:ee12d9dc5cbb 7334:618140c75d8d
   100     for f in files:
   100     for f in files:
   101         o = files[f]
   101         o = files[f]
   102         if o:
   102         if o:
   103             opener(f, "a").truncate(int(o))
   103             opener(f, "a").truncate(int(o))
   104         else:
   104         else:
   105             fn = opener(f).name
   105             try:
   106             os.unlink(fn)
   106                 fn = opener(f).name
       
   107                 os.unlink(fn)
       
   108             except OSError, inst:
       
   109                 if inst.errno != errno.ENOENT:
       
   110                     raise
   107     os.unlink(file)
   111     os.unlink(file)
   108 
   112