Commit 7645ff2
regex/literal: fix bug in Boyer-Moore
This patch fixes an issue where skip resolution would go strait
to the default value (the md2_shift) on a match failure after
the shift_loop. Now we do the right thing, and first check in
the skip table. The problem with going strait to the md2_shift
is that you can accidentally shift to far when `window_end`
actually is in the pattern (as is the case for the failing
match).1 parent 43bb64b commit 7645ff2
1 file changed
+3
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
627 | 627 | | |
628 | 628 | | |
629 | 629 | | |
630 | | - | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
631 | 633 | | |
632 | 634 | | |
633 | 635 | | |
| |||
946 | 948 | | |
947 | 949 | | |
948 | 950 | | |
949 | | - | |
950 | 951 | | |
951 | 952 | | |
952 | 953 | | |
| |||
0 commit comments