From 5fceabe5e5f8f46d64f1fc609dda24a5d39232f3 Mon Sep 17 00:00:00 2001 From: teoberi Date: Fri, 22 Dec 2023 18:38:09 +0200 Subject: [PATCH] clamconf: fix issue printing size types Fixes: https://github.com/Cisco-Talos/clamav/issues/1013 --- clamconf/clamconf.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/clamconf/clamconf.c b/clamconf/clamconf.c index c8b26468af..be7fd3e5e3 100644 --- a/clamconf/clamconf.c +++ b/clamconf/clamconf.c @@ -101,6 +101,7 @@ static void printopts(struct optstruct *opts, int nondef) case CLOPT_TYPE_NUMBER: case CLOPT_TYPE_SIZE: + case CLOPT_TYPE_SIZE64: printf("%s = \"%lld\"", opts->name, opts->numarg); opt = opts; while ((opt = opt->nextarg)) @@ -169,7 +170,8 @@ static int printconf(const char *name) break; case CLOPT_TYPE_SIZE: - printf("# You may use 'M' or 'm' for megabytes (1M = 1m = 1048576 bytes)\n# and 'K' or 'k' for kilobytes (1K = 1k = 1024 bytes). To specify the size\n# in bytes just don't use modifiers.\n"); + case CLOPT_TYPE_SIZE64: + printf("# You may use 'G' or 'g' for gigabytes (1G = 1g = 1,073,741,824 bytes)\n# 'M' or 'm' for megabytes (1M = 1m = 1048576 bytes)\n# and 'K' or 'k' for kilobytes (1K = 1k = 1024 bytes). To specify the size\n# in bytes just don't use modifiers.\n"); if (cpt->numarg != -1) printf("# Default: %lld\n", cpt->numarg); else