We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2870b7d commit 026140bCopy full SHA for 026140b
prism/prism.c
@@ -22639,7 +22639,7 @@ static const char *
22639
pm_strnstr(const char *big, const char *little, size_t big_length) {
22640
size_t little_length = strlen(little);
22641
22642
- for (const char *big_end = big + big_length; big < big_end; big++) {
+ for (const char *max = big + big_length - little_length; big <= max; big++) {
22643
if (*big == *little && memcmp(big, little, little_length) == 0) return big;
22644
}
22645
0 commit comments