lib/getrange.c: getrange(): Return early to remove an else
Signed-off-by: Alejandro Colomar <alx@kernel.org>
This commit is contained in:
committed by
Serge Hallyn
parent
8d8062c770
commit
62a4daa2cd
@@ -64,9 +64,9 @@ getrange(const char *range,
|
||||
break;
|
||||
case '-':
|
||||
endptr++;
|
||||
if ('\0' == *endptr) {
|
||||
/* <long>- */
|
||||
} else if (!isdigit (*endptr)) {
|
||||
if ('\0' == *endptr)
|
||||
return 0; /* <long>- */
|
||||
if (!isdigit (*endptr)) {
|
||||
return -1;
|
||||
} else {
|
||||
errno = 0;
|
||||
|
||||
Reference in New Issue
Block a user