From: Karel Zak Date: Wed, 18 Aug 2021 08:38:52 +0000 (+0200) Subject: ipcmk: fix strtoul use, remove deadcode [coverity scan] X-Git-Tag: v2.38-rc1~289 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=463e96d0bf6e364868fa2b3d7866a52ad345a332;p=thirdparty%2Futil-linux.git ipcmk: fix strtoul use, remove deadcode [coverity scan] Signed-off-by: Karel Zak --- diff --git a/sys-utils/ipcmk.c b/sys-utils/ipcmk.c index d6e5ce6c98..9c1f60868c 100644 --- a/sys-utils/ipcmk.c +++ b/sys-utils/ipcmk.c @@ -125,7 +125,7 @@ int main(int argc, char **argv) { char *end = NULL; errno = 0; - permission = strtoul(optarg, NULL, 8); + permission = strtoul(optarg, &end, 8); if (errno || optarg == end || (end && *end)) err(EXIT_FAILURE, _("failed to parse mode")); break;