summaryrefslogtreecommitdiff
path: root/dgit
diff options
context:
space:
mode:
authorIan Jackson <ijackson@chiark.greenend.org.uk>2014-08-03 18:00:55 +0100
committerIan Jackson <ijackson@chiark.greenend.org.uk>2014-08-03 18:00:55 +0100
commit0efc9955c6c355f5dd6e98c8097bd3938beb49d1 (patch)
tree3b891d96441d16c86d5aaf8dfd573059034c5974 /dgit
parentc0fcc7499118fdba35f817ff2f8765b7a1534e2d (diff)
Do not spew diff output to terminal (by default). Print sensible message instead. Closes:#736526.
Diffstat (limited to 'dgit')
-rwxr-xr-xdgit5
1 files changed, 3 insertions, 2 deletions
diff --git a/dgit b/dgit
index 1fdca6c..843c7ec 100755
--- a/dgit
+++ b/dgit
@@ -1395,8 +1395,9 @@ sub dopush () {
my @diffcmd = (@git, qw(diff), $diffopt, $tree);
printcmd \*DEBUG,$debugprefix."+",@diffcmd;
$!=0; $?=0;
- if (system @diffcmd) {
- if ($! && $?==256) {
+ my $r = system @diffcmd;
+ if ($r) {
+ if ($r==256) {
fail "$dscfn specifies a different tree to your HEAD commit;".
" perhaps you forgot to build".
($diffopt eq '--exit-code' ? "" :