Skip to content

Commit af1032e

Browse files
René Scharfegitster
authored andcommitted
apply: use OPT_NOOP_NOARG
Signed-off-by: Rene Scharfe <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 7cfc605 commit af1032e

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

builtin/apply.c

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3831,7 +3831,6 @@ int cmd_apply(int argc, const char **argv, const char *prefix_)
38313831
int i;
38323832
int errs = 0;
38333833
int is_not_gitdir = !startup_info->have_repository;
3834-
int binary;
38353834
int force_apply = 0;
38363835

38373836
const char *whitespace_option = NULL;
@@ -3850,12 +3849,8 @@ int cmd_apply(int argc, const char **argv, const char *prefix_)
38503849
"ignore additions made by the patch"),
38513850
OPT_BOOLEAN(0, "stat", &diffstat,
38523851
"instead of applying the patch, output diffstat for the input"),
3853-
{ OPTION_BOOLEAN, 0, "allow-binary-replacement", &binary,
3854-
NULL, "old option, now no-op",
3855-
PARSE_OPT_HIDDEN | PARSE_OPT_NOARG },
3856-
{ OPTION_BOOLEAN, 0, "binary", &binary,
3857-
NULL, "old option, now no-op",
3858-
PARSE_OPT_HIDDEN | PARSE_OPT_NOARG },
3852+
OPT_NOOP_NOARG(0, "allow-binary-replacement"),
3853+
OPT_NOOP_NOARG(0, "binary"),
38593854
OPT_BOOLEAN(0, "numstat", &numstat,
38603855
"shows number of added and deleted lines in decimal notation"),
38613856
OPT_BOOLEAN(0, "summary", &summary,

0 commit comments

Comments
 (0)