Browse Source

merge-recursive: Replace 'except:'

Plain except:s are evil as they will catch all kinds of exceptions
including NameError and AttrubiteError.

Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
maint
Fredrik Kuivinen 20 years ago committed by Junio C Hamano
parent
commit
a6322d079b
  1. 4
      git-merge-recursive.py

4
git-merge-recursive.py

@ -245,7 +245,7 @@ def updateFileExt(sha, mode, path, updateCache, updateWd): @@ -245,7 +245,7 @@ def updateFileExt(sha, mode, path, updateCache, updateWd):

try:
createDir = not stat.S_ISDIR(os.lstat(p).st_mode)
except:
except OSError:
createDir = True
if createDir:
@ -295,7 +295,7 @@ def removeFile(clean, path): @@ -295,7 +295,7 @@ def removeFile(clean, path):
raise
try:
os.removedirs(os.path.dirname(path))
except:
except OSError:
pass

def uniquePath(path, branch):

Loading…
Cancel
Save