lib: fix some strtoul() use cases

...otherwise 4294967295 is not a valid value on 32bit systems
4 files changed