summaryrefslogtreecommitdiff
path: root/diff.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2010-02-16 23:05:02 (GMT)
committerJunio C Hamano <gitster@pobox.com>2010-02-16 23:05:02 (GMT)
commite7b3cea0f7589c57f7bb808330e32bdd7f901c95 (patch)
treef5612fd7df20b7d7273ddf44b30117e6eb1764a9 /diff.c
parentb599672316ae0e0cf827e5e2cd6d3bb403d7b8cd (diff)
parenteb0bcd0fbe34befe7648a398efc7f4156b07da48 (diff)
downloadgit-e7b3cea0f7589c57f7bb808330e32bdd7f901c95.zip
git-e7b3cea0f7589c57f7bb808330e32bdd7f901c95.tar.gz
git-e7b3cea0f7589c57f7bb808330e32bdd7f901c95.tar.bz2
Merge branch 'maint-1.6.6' into maint
* maint-1.6.6: dwim_ref: fix dangling symref warning stash pop: remove 'apply' options during 'drop' invocation diff: make sure --output=/bad/path is caught Remove hyphen from "git-command" in two error messages
Diffstat (limited to 'diff.c')
-rw-r--r--diff.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/diff.c b/diff.c
index 381cc8d..68def6c 100644
--- a/diff.c
+++ b/diff.c
@@ -2893,6 +2893,8 @@ int diff_opt_parse(struct diff_options *options, const char **av, int ac)
;
else if (!prefixcmp(arg, "--output=")) {
options->file = fopen(arg + strlen("--output="), "w");
+ if (!options->file)
+ die_errno("Could not open '%s'", arg + strlen("--output="));
options->close_file = 1;
} else
return 0;