提交 a6322d07 编写于 作者: F Fredrik Kuivinen 提交者: Junio C Hamano

merge-recursive: Replace 'except:'

Plain except:s are evil as they will catch all kinds of exceptions
including NameError and AttrubiteError.
Signed-off-by: NFredrik Kuivinen <freku045@student.liu.se>
Signed-off-by: NJunio C Hamano <junkio@cox.net>
上级 9ae2172a
......@@ -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):
raise
try:
os.removedirs(os.path.dirname(path))
except:
except OSError:
pass
def uniquePath(path, branch):
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册