summaryrefslogtreecommitdiff
path: root/src/lib/libc/stdlib/strtoumax.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libc/stdlib/strtoumax.c')
-rw-r--r--src/lib/libc/stdlib/strtoumax.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libc/stdlib/strtoumax.c b/src/lib/libc/stdlib/strtoumax.c
index 4c5e3349f1..348184c1ac 100644
--- a/src/lib/libc/stdlib/strtoumax.c
+++ b/src/lib/libc/stdlib/strtoumax.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: strtoumax.c,v 1.3 2015/09/12 16:23:14 guenther Exp $ */ 1/* $OpenBSD: strtoumax.c,v 1.4 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.
@@ -68,8 +68,8 @@ strtoumax(const char *nptr, char **endptr, int base)
68 if (c == '+') 68 if (c == '+')
69 c = *s++; 69 c = *s++;
70 } 70 }
71 if ((base == 0 || base == 16) && 71 if ((base == 0 || base == 16) && c == '0' &&
72 c == '0' && (*s == 'x' || *s == 'X')) { 72 (*s == 'x' || *s == 'X') && isxdigit((unsigned char)s[1])) {
73 c = s[1]; 73 c = s[1];
74 s += 2; 74 s += 2;
75 base = 16; 75 base = 16;