summaryrefslogtreecommitdiff
path: root/ext/pcre/php_pcre.c
diff options
context:
space:
mode:
authorNuno Lopes <nlopess@php.net>2009-04-10 15:47:15 +0000
committerNuno Lopes <nlopess@php.net>2009-04-10 15:47:15 +0000
commitae57857ebac7ced6e8ec985e916ed2bbc8c27eb4 (patch)
tree6e5ed82289c05a9e84ae37e94bed146539933218 /ext/pcre/php_pcre.c
parentc1ccccc658554c4e0c83a26165cb3802b4f75950 (diff)
downloadphp-git-ae57857ebac7ced6e8ec985e916ed2bbc8c27eb4.tar.gz
fix bug #47662: support more than 127 named subpatterns
Diffstat (limited to 'ext/pcre/php_pcre.c')
-rw-r--r--ext/pcre/php_pcre.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c
index 496418a72e..7d414a3858 100644
--- a/ext/pcre/php_pcre.c
+++ b/ext/pcre/php_pcre.c
@@ -209,7 +209,7 @@ static char **make_subpats_table(int num_subpats, pcre_cache_entry *pce TSRMLS_D
}
while (ni++ < name_cnt) {
- name_idx = 0xff * name_table[0] + name_table[1];
+ name_idx = 0xff * (unsigned char)name_table[0] + (unsigned char)name_table[1];
subpat_names[name_idx] = name_table + 2;
if (is_numeric_string(subpat_names[name_idx], strlen(subpat_names[name_idx]), NULL, NULL, 0) > 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Numeric named subpatterns are not allowed");