diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/cg-base.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/cg-base.c b/src/cg-base.c index a8c7f71..d9da32a 100644 --- a/src/cg-base.c +++ b/src/cg-base.c @@ -653,7 +653,13 @@ int main(int argc, char* argv[]) return 0; } else if (prio != NULL) - priority = (int64_t)atoll(prio); + { + char *end; + errno = 0; + priority = (int64_t)strtoll(prio, &end, 10); + if (errno || *end) + usage(); + } if (!nulstrcmp(rule, "??")) { |