aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2005-04-28 08:20:33 +0000
committerDaniel Stenberg <daniel@haxx.se>2005-04-28 08:20:33 +0000
commit9fb253388b08d53ab64e96d77857b7e51fcf4502 (patch)
tree65a70834ecf6f4ab6a66b4221c793415e5f817a9
parent8cf17862965ab409ecac07f1330352bd78d362b8 (diff)
if diff -u makes zero output, try diff -c instead
-rw-r--r--tests/getpart.pm6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/getpart.pm b/tests/getpart.pm
index 898ecec6b..d1c8ec856 100644
--- a/tests/getpart.pm
+++ b/tests/getpart.pm
@@ -220,7 +220,11 @@ sub showdiff {
print TEMP $_;
}
close(TEMP);
- my @out = `diff -u $file2 $file1`;
+ my @out = `diff -u $file2 $file1 2>/dev/null`;
+
+ if(!$out[0]) {
+ @out = `diff -c $file2 $file1 2>/dev/null`;
+ }
return @out;
}