Skip to content

Commit

Permalink
Merge branch 'jc/fix-diff-no-index-diff-opt-parse' into maint
Browse files Browse the repository at this point in the history
* jc/fix-diff-no-index-diff-opt-parse:
  diff-no-index: correctly diagnose error return from diff_opt_parse()
  • Loading branch information
gitster committed Apr 9, 2014
2 parents efb4ec6 + ad1c3fb commit 693b407
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion diff-no-index.c
Expand Up @@ -202,7 +202,7 @@ void diff_no_index(struct rev_info *revs,
i++;
else {
j = diff_opt_parse(&revs->diffopt, argv + i, argc - i);
if (!j)
if (j <= 0)
die("invalid diff option/value: %s", argv[i]);
i += j;
}
Expand Down

0 comments on commit 693b407

Please sign in to comment.