]> www.infradead.org Git - users/sagi/nvme-cli.git/commitdiff
util: remove argconfig CFG_SIZE type
authorCaleb Sander Mateos <csander@purestorage.com>
Tue, 16 Jul 2024 18:42:44 +0000 (12:42 -0600)
committerDaniel Wagner <wagi@monom.org>
Wed, 17 Jul 2024 14:57:45 +0000 (16:57 +0200)
CFG_SIZE is unused and not handled by argconfig_set_opt_val().

Signed-off-by: Caleb Sander Mateos <csander@purestorage.com>
util/argconfig.c
util/argconfig.h

index 5ec3d6f215f5d792da326aa2544f100e269611ed..88bcd10f9f0db79f193dddab6c83dcacf88f83d7 100644 (file)
@@ -170,11 +170,6 @@ static int argconfig_parse_type(struct argconfig_commandline_options *s, struct
        case CFG_STRING:
                *((char **)value) = optarg;
                break;
-       case CFG_SIZE:
-               *((size_t *)value) = strtol(optarg, &endptr, 0);
-               if (errno || optarg == endptr)
-                       ret = argconfig_error("integer", option[index].name, optarg);
-               break;
        case CFG_INT:
                *((int *)value) = strtol(optarg, &endptr, 0);
                if (errno || optarg == endptr)
index 2a04a32e7236d3c220d7fa5f0720a7f2e1624496..17ff5fa10b39590632346bd8997634405f51b4af 100644 (file)
@@ -47,7 +47,6 @@ enum argconfig_types {
        CFG_FLAG,
        CFG_STRING,
        CFG_INT,
-       CFG_SIZE,
        CFG_LONG,
        CFG_LONG_SUFFIX,
        CFG_DOUBLE,