summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>2022-11-07 23:32:59 +0000
committerGerrit Code Review <gerrit@wikimedia.org>2022-11-07 23:32:59 +0000
commit18cd17fa57dcf401ba71b3d8d338b224d48cf62e (patch)
treefba40c4934d162345bc89797ad514d107f32c891
parenta8c49ecbffb2e04f0fa471278326a487819bc7e5 (diff)
parent8ac6410f75e29ec70fcf53683741ca6128263400 (diff)
Merge "Fix off-by-1 error in Preprocessor_Hash"wmf/1.40.0-wmf.9
-rw-r--r--includes/parser/Preprocessor_Hash.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/includes/parser/Preprocessor_Hash.php b/includes/parser/Preprocessor_Hash.php
index 0e530644bfd3..5008193cf081 100644
--- a/includes/parser/Preprocessor_Hash.php
+++ b/includes/parser/Preprocessor_Hash.php
@@ -331,7 +331,7 @@ class Preprocessor_Hash extends Preprocessor {
// comments.
$comments = [ [ $wsStart, $wsEnd ] ];
while ( substr( $text, $wsEnd + 1, 4 ) == '<!--' ) {
- $c = strpos( $text, '-->', $wsEnd + 4 );
+ $c = strpos( $text, '-->', $wsEnd + 5 );
if ( $c === false ) {
break;
}