From 5fb308bca2f333dcc835945be85e165cd7843d5b Mon Sep 17 00:00:00 2001 From: Eric Blake Date: Wed, 6 Oct 2010 13:48:07 -0400 Subject: Fix strstr and memmem algorithm. --- string/str-two-way.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'string/str-two-way.h') diff --git a/string/str-two-way.h b/string/str-two-way.h index 502af47046..76044b34fe 100644 --- a/string/str-two-way.h +++ b/string/str-two-way.h @@ -350,8 +350,8 @@ two_way_long_needle (const unsigned char *haystack, size_t haystack_len, a byte out of place, there can be no match until after the mismatch. */ shift = needle_len - period; - memory = 0; } + memory = 0; j += shift; continue; } -- cgit 1.4.1