lib/replace: Make sure that replacement strto[u]ll does not reset errno unexpectedly
authorFelix Janda <felix.janda@posteo.de>
Thu, 22 Oct 2015 10:37:55 +0000 (12:37 +0200)
committerStefan Metzmacher <metze@samba.org>
Sat, 31 Oct 2015 21:03:14 +0000 (22:03 +0100)
commit89d254ddca20a36001c9dfdcfa6d8b9767f0f897
tree75f0b11091bd89298643c39f70348e74358aaa40
parent8343c707533e9acd53898778f386a1d93d57763f
lib/replace: Make sure that replacement strto[u]ll does not reset errno unexpectedly

Fix the replacement functions for strtoll and strtoull to not set errno
to 0 if errno is EINVAL before calling, strto[u]ll does not modify errno
and the base is ok.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11455

Signed-off-by: Felix Janda <felix.janda@posteo.de>
Reviewed-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
lib/replace/replace.c