mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-29 03:45:43 +00:00
add range check
This commit is contained in:
1 parent
0ebf9a11f9
commit
7da32cb56b
1 file changed
+5
@@ -214,6 +214,11 @@ PHP_FUNCTION(dom_namednodemap_item)
|
||||
return;
|
||||
}
|
||||
if (index >= 0) {
|
||||
if (ZEND_LONG_INT_OVFL(index)) {
|
||||
php_error_docref(NULL, E_WARNING, "Invalid index");
|
||||
RETURN_NULL();
|
||||
}
|
||||
|
||||
intern = Z_DOMOBJ_P(id);
|
||||
|
||||
objmap = (dom_nnodemap_object *)intern->ptr;
|
||||
|
||||
Reference in new issue
Block a user