[PATCH v2 1/7] parse-options: require PARSE_OPT_NOARG for OPTION_BITOP

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



OPTION_BITOP options don't take arguments.  Make sure they are declared
that way using the flag PARSE_OPT_NOARG.

Signed-off-by: René Scharfe <l.s.r@xxxxxx>
---
 parse-options.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/parse-options.c b/parse-options.c
index a9a39ecaef..68ff494492 100644
--- a/parse-options.c
+++ b/parse-options.c
@@ -591,6 +591,7 @@ static void parse_options_check(const struct option *opts)
 		case OPTION_NEGBIT:
 		case OPTION_SET_INT:
 		case OPTION_NUMBER:
+		case OPTION_BITOP:
 			if ((opts->flags & PARSE_OPT_OPTARG) ||
 			    !(opts->flags & PARSE_OPT_NOARG))
 				optbug(opts, "should not accept an argument");
-- 
2.50.0





[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux