0
0
Fork 0
mirror of https://git.do.srb2.org/STJr/SRB2.git synced 2025-04-18 00:11:48 +00:00

Fix strcasestr SIGSEGV in the case of only upper case strchr returning NULL

This commit is contained in:
James R 2019-11-19 11:16:17 -08:00
parent d1d1098f7c
commit c5d73e37bb

View file

@ -75,7 +75,7 @@ strcasestr (const char *s, const char *q)
if (!( (intptr_t)up|(intptr_t)lp ))
return 0;
if (!lp || up < lp)
if (!lp || ( up && up < lp ))
{
ppa = &up;
ppb = &lp;