Skip to content
Commit 2d49a208 authored by Lennart Poettering's avatar Lennart Poettering
Browse files

parse-util: really refuse parsing negative values as positive ones, even on x86-32

strtoull() doesn't make it particularly easy to detect passed-in
negative numbers, as it silently converts them to positive ones without
generating any error. Since we are not interested in negative values we
should hence explicitly filter them out by looking at the string
directly and returning ERANGE if we see a leading "-".

Fixes: #1829
parent b374689c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment