mirror of
https://github.com/php/php-src.git
synced 2025-08-20 17:34:35 +02:00
Fix bug #71540 - NULL pointer dereference in xsl_ext_function_php()
This commit is contained in:
parent
e18910c296
commit
889e3b62f4
2 changed files with 71 additions and 0 deletions
|
@ -231,6 +231,10 @@ static void xsl_ext_function_php(xmlXPathParserContextPtr ctxt, int nargs, int t
|
|||
/* Reverse order to pop values off ctxt stack */
|
||||
for (i = nargs - 2; i >= 0; i--) {
|
||||
obj = valuePop(ctxt);
|
||||
if (obj == NULL) {
|
||||
ZVAL_NULL(&args[i]);
|
||||
continue;
|
||||
}
|
||||
switch (obj->type) {
|
||||
case XPATH_STRING:
|
||||
ZVAL_STRING(&args[i], (char *)obj->stringval);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue