Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

lib/kstrtox.c: remove redundant cleanup

We can't reach the cleanup code unless the flag KSTRTOX_OVERFLOW is not
set, so there's not no point in clearing a bit that we know is not set.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Acked-by: Levente Kurusa <levex@linux.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Felipe Contreras and committed by
Linus Torvalds
ae2924a2 68585c41

-1
-1
lib/kstrtox.c
··· 92 92 rv = _parse_integer(s, base, &_res); 93 93 if (rv & KSTRTOX_OVERFLOW) 94 94 return -ERANGE; 95 - rv &= ~KSTRTOX_OVERFLOW; 96 95 if (rv == 0) 97 96 return -EINVAL; 98 97 s += rv;