== kernel source identity (guest /usr/src vs repo sys/) == 370024243 4183 /usr/src/sys/libkern/strtol.c 3544205135 3234 /usr/src/sys/libkern/strtoul.c cksum: illegal option -- a usage: cksum [-o 1 | 2 | 3] [file ...] sum [file ...] == generating userland-compilable copies via sed (no hand edits) == k_strtol_fix.c: 1 isxdigit guard site(s) (expect 1) k_strtoul_fix.c: 1 isxdigit guard site(s) (expect 1) == diff of fix vs baseline (must be ONLY the guard) == --- k_strtol.c 2026-10-10 07:50:51.045006000 +0000 +++ k_strtol_fix.c 2026-10-10 07:50:51.055082000 +0000 @@ -43,7 +43,7 @@ * alphabets and digits are each contiguous. */ long -k_strtol(const char *nptr, char **endptr, int base) +k_strtol_fix(const char *nptr, char **endptr, int base) { const char *s = nptr; unsigned long acc; @@ -65,7 +65,7 @@ } else if (c == '+') c = *s++; if ((base == 0 || base == 16) && - c == '0' && (*s == 'x' || *s == 'X')) { + c == '0' && (*s == 'x' || *s == 'X') && isxdigit((unsigned char)s[1])) { c = s[1]; s += 2; base = 16; --- k_strtoul.c 2026-10-10 07:50:51.055082000 +0000 +++ k_strtoul_fix.c 2026-10-10 07:50:51.065120000 +0000 @@ -43,7 +43,7 @@ * alphabets and digits are each contiguous. */ unsigned long -k_strtoul(const char *nptr, char **endptr, int base) +k_strtoul_fix(const char *nptr, char **endptr, int base) { const char *s = nptr; unsigned long acc; @@ -63,7 +63,7 @@ } else if (c == '+') c = *s++; if ((base == 0 || base == 16) && - c == '0' && (*s == 'x' || *s == 'X')) { + c == '0' && (*s == 'x' || *s == 'X') && isxdigit((unsigned char)s[1])) { c = s[1]; s += 2; base = 16; == compile == build OK: /tmp/df5703/diffharness