Skip to content

Commit

Permalink
diff --no-index -q: fix endless loop
Browse files Browse the repository at this point in the history
We forgot to move to the next argument when parsing -q, getting stuck
in an endless loop.

Signed-off-by: Thomas Rast <trast@student.ethz.ch>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Thomas Rast authored and Junio C Hamano committed Jan 7, 2009
1 parent c6dbca0 commit a324fc4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion diff-no-index.c
Original file line number Diff line number Diff line change
Expand Up @@ -207,8 +207,10 @@ void diff_no_index(struct rev_info *revs,
int j;
if (!strcmp(argv[i], "--no-index"))
i++;
else if (!strcmp(argv[i], "-q"))
else if (!strcmp(argv[i], "-q")) {
options |= DIFF_SILENT_ON_REMOVED;
i++;
}
else if (!strcmp(argv[i], "--"))
i++;
else {
Expand Down

0 comments on commit a324fc4

Please sign in to comment.