com php-src: Reset fields: ext/ffi/ffi.c

From: Date: Mon, 11 Mar 2019 12:38:49 +0000
Subject: com php-src: Reset fields: ext/ffi/ffi.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-105075@lists.php.net to get a copy of this message
Commit: e7f0a60d54d4c6820141251b51f62d8c3424d467 Author: Dmitry Stogov <dmitry@zend.com> Mon, 11 Mar 2019 15:38:49 +0300 Parents: e623df650fd099325154ffd43cc19002e1cb619e Branches: PHP-7.4 master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=e7f0a60d54d4c6820141251b51f62d8c3424d467 Log: Reset fields Changed paths: M ext/ffi/ffi.c Diff: diff --git a/ext/ffi/ffi.c b/ext/ffi/ffi.c index f9c7fe0..1885c63 100644 --- a/ext/ffi/ffi.c +++ b/ext/ffi/ffi.c @@ -1877,8 +1877,11 @@ static int zend_ffi_cdata_get_closure(zval *obj, zend_class_entry **ce_ptr, zend /* set to 0 to avoid arg_info[] allocation, because all values are passed by value anyway */ func->common.num_args = 0; func->common.required_num_args = type->func.args ? zend_hash_num_elements(type->func.args) : 0; + func->common.scope = NULL; + func->common.prototype = NULL; func->common.arg_info = NULL; func->internal_function.handler = ZEND_FN(ffi_trampoline); + func->internal_function.module = NULL; func->internal_function.reserved[0] = type; func->internal_function.reserved[1] = *(void**)cdata->ptr; @@ -2607,8 +2610,11 @@ static zend_function *zend_ffi_get_func(zend_object **obj, zend_string *name, co /* set to 0 to avoid arg_info[] allocation, because all values are passed by value anyway */ func->common.num_args = 0; func->common.required_num_args = type->func.args ? zend_hash_num_elements(type->func.args) : 0; + func->common.scope = NULL; + func->common.prototype = NULL; func->common.arg_info = NULL; func->internal_function.handler = ZEND_FN(ffi_trampoline); + func->internal_function.module = NULL; func->internal_function.reserved[0] = type; func->internal_function.reserved[1] = sym->addr;

« previous php.cvs (#105075) next »