Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
difftool: silence warning
author
Ross Lagerwall
<rosslagerwall@gmail.com>
Tue, 21 Aug 2012 10:21:40 +0000
(12:21 +0200)
committer
Junio C Hamano
<gitster@pobox.com>
Tue, 21 Aug 2012 22:27:15 +0000
(15:27 -0700)
Silence a warning given when running git difftool --dir-diff and
there are no changes.
This is because command_oneline returns undef when the command has no
output, not ''.
Signed-off-by: Ross Lagerwall <rosslagerwall@gmail.com>
Acked-by: David Aguilar <davvid@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-difftool.perl
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(parent:
755e8b3
)
diff --git
a/git-difftool.perl
b/git-difftool.perl
index 17d4de661820e8c7ae24694a21458be825b1ac9a..edd0493a08b501d60c04044e79a9e0b096d77953 100755
(executable)
--- a/
git-difftool.perl
+++ b/
git-difftool.perl
@@
-138,7
+138,7
@@
sub setup_dir_diff
my @gitargs = ('diff', '--raw', '--no-abbrev', '-z', @ARGV);
my $diffrtn = $diffrepo->command_oneline(@gitargs);
- exit(0)
if (length($diffrtn) == 0
);
+ exit(0)
unless defined($diffrtn
);
# Build index info for left and right sides of the diff
my $submodule_mode = '160000';