author | Johannes Sixt <j6t@kdbg.org> | |
Sat, 4 Jul 2009 19:26:41 +0000 (21:26 +0200) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 6 Jul 2009 09:44:56 +0000 (02:44 -0700) | ||
commit | b99d5f40d6a5cba7d7cd7599063b3cd78aa4d219 | |
tree | 81b30533566611db8564458de11006646d7bf61d | tree | snapshot |
parent | 0ac77ec3150f43a5c2a6b1e47e9db5aafe53fb72 | commit | diff |
run_command: encode deadly signal number in the return value
We now write the signal number in the error message if the program
terminated by a signal. The negative return value is constructed such that
after truncation to 8 bits it looks like a POSIX shell's $?:
$ echo 0000 | { git upload-pack .; echo $? >&2; } | :
error: git-upload-pack died of signal 13
141
Previously, the exit code was 255 instead of 141.
Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
We now write the signal number in the error message if the program
terminated by a signal. The negative return value is constructed such that
after truncation to 8 bits it looks like a POSIX shell's $?:
$ echo 0000 | { git upload-pack .; echo $? >&2; } | :
error: git-upload-pack died of signal 13
141
Previously, the exit code was 255 instead of 141.
Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
run-command.c | diff | blob | history |