mirror of
https://github.com/php/php-src.git
synced 2026-04-11 01:53:36 +02:00
zend_compile_file returns a NULL on error, check for that before
calling destroy_op_array unless we like crashes :-)
This commit is contained in:
@@ -1263,7 +1263,8 @@ PHPAPI int php_lint_script(zend_file_handle *file CLS_DC ELS_DC PLS_DC)
|
||||
|
||||
op_array = zend_compile_file(file, ZEND_INCLUDE CLS_CC);
|
||||
retval = (op_array?SUCCESS:FAILURE);
|
||||
destroy_op_array(op_array);
|
||||
/* SMC op_array may be NULL */
|
||||
if (op_array != NULL) destroy_op_array(op_array);
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user