diff: reject unknown change class given to --diff-filter

We used to accept "git diff --diff-filter=Q" (note that there is no such change class 'Q') silently and showed no output (because there is no such change class 'Q'). Error out when such an input is given. Signed-off-by: Junio C Hamano <gitster@pobox.com>

Junio C Hamano committed Jul 17, 2013 at 15:27 UTC bf142ec4346385553918bc53f203b205091aa362
1 file changed +1 -1
diff.c
+1 -1
@@ -3537,7 +3537,7 @@ static int parse_diff_filter_opt(const char *optarg, struct diff_options *opt)
3537
3538 bit = (0 <= optch && optch <= 'Z') ? filter_bit[optch] : 0;
3539 if (!bit)
3540 - continue; /* ignore unknown ones, like we always have */
3540 + return optarg[i];
3541 opt->filter |= bit;
3542 }
3543 return 0;