From: Simon Hausmann Date: Wed, 23 May 2007 21:27:31 +0000 (+0200) Subject: Don't make len(p4Cmd("p4 changes -m 1 //foo/...")) == 0 succeed when the p4 command... X-Git-Tag: v1.5.3-rc0~65^2^2~68 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=a6d5da36af9a7087cf14e717b72c66ef2c34eb3b;p=git.git Don't make len(p4Cmd("p4 changes -m 1 //foo/...")) == 0 succeed when the p4 command itself failed. When the p4 command failed write out the exit code in the returned dict. Signed-off-by: Simon Hausmann --- diff --git a/contrib/fast-import/git-p4 b/contrib/fast-import/git-p4 index f12ad8baf..89a85ebb1 100755 --- a/contrib/fast-import/git-p4 +++ b/contrib/fast-import/git-p4 @@ -31,7 +31,9 @@ def p4CmdList(cmd): result.append(entry) except EOFError: pass - pipe.close() + exitCode = pipe.close() + if exitCode != None: + result["p4ExitCode"] = exitCode return result