mirror of
https://github.com/git/git
synced 2024-08-24 18:26:02 +00:00
parse-options.c: turn some die() to BUG()
These two strings are clearly not for the user to see. Reduce the violence in one string while at there. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
9440b831ad
commit
48a5499ef5
|
@ -197,7 +197,7 @@ static int get_value(struct parse_opt_ctx_t *p,
|
|||
return 0;
|
||||
|
||||
default:
|
||||
die("should not happen, someone must be hit on the forehead");
|
||||
BUG("opt->type %d should not happen", opt->type);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -424,7 +424,7 @@ void parse_options_start(struct parse_opt_ctx_t *ctx,
|
|||
ctx->flags = flags;
|
||||
if ((flags & PARSE_OPT_KEEP_UNKNOWN) &&
|
||||
(flags & PARSE_OPT_STOP_AT_NON_OPTION))
|
||||
die("STOP_AT_NON_OPTION and KEEP_UNKNOWN don't go together");
|
||||
BUG("STOP_AT_NON_OPTION and KEEP_UNKNOWN don't go together");
|
||||
parse_options_check(options);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue