##// END OF EJS Templates
util.unlink should only catch OSError.
Vadim Gelfer -
r2064:547ede01 default
parent child Browse files
Show More
@@ -373,8 +373,10 b' def unlink(f):'
373 """unlink and remove the directory if it is empty"""
373 """unlink and remove the directory if it is empty"""
374 os.unlink(f)
374 os.unlink(f)
375 # try removing directories that might now be empty
375 # try removing directories that might now be empty
376 try: os.removedirs(os.path.dirname(f))
376 try:
377 except: pass
377 os.removedirs(os.path.dirname(f))
378 except OSError:
379 pass
378
380
379 def copyfiles(src, dst, hardlink=None):
381 def copyfiles(src, dst, hardlink=None):
380 """Copy a directory tree using hardlinks if possible"""
382 """Copy a directory tree using hardlinks if possible"""
General Comments 0
You need to be logged in to leave comments. Login now