mercurial/windows.py
changeset 13777 f6e5035dc81a
parent 13775 930efdc6bfa4
child 13879 5b0a3f6cbead
equal deleted inserted replaced
13776:a2f0fdb1e488 13777:f6e5035dc81a
   284             break
   284             break
   285         head, tail = os.path.split(head)
   285         head, tail = os.path.split(head)
   286 
   286 
   287 def unlinkpath(f):
   287 def unlinkpath(f):
   288     """unlink and remove the directory if it is empty"""
   288     """unlink and remove the directory if it is empty"""
   289     os.unlink(f)
   289     unlink(f)
   290     # try removing directories that might now be empty
   290     # try removing directories that might now be empty
   291     try:
   291     try:
   292         _removedirs(os.path.dirname(f))
   292         _removedirs(os.path.dirname(f))
   293     except OSError:
   293     except OSError:
   294         pass
   294         pass