summaryrefslogtreecommitdiff
path: root/ext/standard/string.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/standard/string.c')
-rw-r--r--ext/standard/string.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/standard/string.c b/ext/standard/string.c
index f4bb26005d..54f680a00d 100644
--- a/ext/standard/string.c
+++ b/ext/standard/string.c
@@ -4519,12 +4519,13 @@ PHPAPI size_t php_strip_tags_ex(char *rbuf, int len, int *stateptr, char *allow,
/* fall-through */
case 'l':
+ case 'L':
/* swm: If we encounter '<?xml' then we shouldn't be in
* state == 2 (PHP). Switch back to HTML.
*/
- if (state == 2 && p > buf+2 && *(p-1) == 'm' && *(p-2) == 'x') {
+ if (state == 2 && p > buf+2 && strncasecmp(p-2, "xm", 2) == 0) {
state = 1;
break;
}