diff options
Diffstat (limited to 'libc/posix/fnmatch_loop.c')
-rw-r--r-- | libc/posix/fnmatch_loop.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libc/posix/fnmatch_loop.c b/libc/posix/fnmatch_loop.c index 53ced9352..858919e7e 100644 --- a/libc/posix/fnmatch_loop.c +++ b/libc/posix/fnmatch_loop.c @@ -419,7 +419,7 @@ FCT (pattern, string, string_end, no_leading_period, flags, ends, alloca_used) _NL_CURRENT (LC_COLLATE, _NL_COLLATE_INDIRECTMB); # endif - idx = findidx (&cp); + idx = findidx (&cp, 1); if (idx != 0) { /* We found a table entry. Now see whether the @@ -429,7 +429,7 @@ FCT (pattern, string, string_end, no_leading_period, flags, ends, alloca_used) int32_t idx2; const UCHAR *np = (const UCHAR *) n; - idx2 = findidx (&np); + idx2 = findidx (&np, string_end - n); if (idx2 != 0 && (idx >> 24) == (idx2 >> 24) && len == weights[idx2 & 0xffffff]) |