]> git.ipfire.org Git - thirdparty/shadow.git/commit
lib/getrange.c: getrange(): Small refactor
authorAlejandro Colomar <alx@kernel.org>
Mon, 15 Apr 2024 09:18:46 +0000 (11:18 +0200)
committerSerge Hallyn <serge@hallyn.com>
Sat, 4 May 2024 22:22:57 +0000 (17:22 -0500)
commit6bf5d6d4f33c3df769ca22d39f76fd2b4c698774
tree730c18cc7e4f67b0955b33193809656a2bab47e3
parentdbd3527c032bcabf6969977b033049cd3e9bc4e6
lib/getrange.c: getrange(): Small refactor

Set *has_{min,max} = false at the begining, so we only need to set them
to true later.

This means we set these variables on error, which we didn't do before,
but since we return -1 on error and ignore (don't use) the pointees at
call site, that's fine.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
lib/getrange.c