diff options
Diffstat (limited to 'src/lib/libc/stdlib/strtoll.c')
-rw-r--r-- | src/lib/libc/stdlib/strtoll.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libc/stdlib/strtoll.c b/src/lib/libc/stdlib/strtoll.c index 0ba51da77e..d21a249a0b 100644 --- a/src/lib/libc/stdlib/strtoll.c +++ b/src/lib/libc/stdlib/strtoll.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: strtoll.c,v 1.9 2015/09/13 08:31:48 guenther Exp $ */ | 1 | /* $OpenBSD: strtoll.c,v 1.10 2017/07/06 16:23:11 millert Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 1992 The Regents of the University of California. | 3 | * Copyright (c) 1992 The Regents of the University of California. |
4 | * All rights reserved. | 4 | * All rights reserved. |
@@ -77,8 +77,8 @@ strtoll(const char *nptr, char **endptr, int base) | |||
77 | if (c == '+') | 77 | if (c == '+') |
78 | c = *s++; | 78 | c = *s++; |
79 | } | 79 | } |
80 | if ((base == 0 || base == 16) && | 80 | if ((base == 0 || base == 16) && c == '0' && |
81 | c == '0' && (*s == 'x' || *s == 'X')) { | 81 | (*s == 'x' || *s == 'X') && isxdigit((unsigned char)s[1])) { |
82 | c = s[1]; | 82 | c = s[1]; |
83 | s += 2; | 83 | s += 2; |
84 | base = 16; | 84 | base = 16; |