diff options
author | Dmitry Stogov <dmitry@zend.com> | 2018-05-29 17:58:06 +0300 |
---|---|---|
committer | Dmitry Stogov <dmitry@zend.com> | 2018-05-29 17:58:06 +0300 |
commit | d90c6f2443d3c8b4e1e83b3e0fbfc58d1fe5e84f (patch) | |
tree | b651c9cea24d5fd0c82796e498a46f1b96b40e4d /main | |
parent | 44be0fa67b46506353c3dd27d97801bd0eddbb00 (diff) | |
download | php-git-d90c6f2443d3c8b4e1e83b3e0fbfc58d1fe5e84f.tar.gz |
Removed useless zval_ptr_dtor()
Diffstat (limited to 'main')
-rw-r--r-- | main/streams/userspace.c | 33 |
1 files changed, 16 insertions, 17 deletions
diff --git a/main/streams/userspace.c b/main/streams/userspace.c index fedcc3f8bb..5f70e0ac73 100644 --- a/main/streams/userspace.c +++ b/main/streams/userspace.c @@ -689,11 +689,11 @@ static size_t php_userstreamop_read(php_stream *stream, char *buf, size_t count) ZVAL_STRINGL(&func_name, USERSTREAM_EOF, sizeof(USERSTREAM_EOF)-1); - call_result = call_user_function_ex(NULL, + call_result = call_user_function(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, - 0, NULL, 0, NULL); + 0, NULL); if (call_result == SUCCESS && Z_TYPE(retval) != IS_UNDEF && zval_is_true(&retval)) { stream->eof = 1; @@ -721,11 +721,11 @@ static int php_userstreamop_close(php_stream *stream, int close_handle) ZVAL_STRINGL(&func_name, USERSTREAM_CLOSE, sizeof(USERSTREAM_CLOSE)-1); - call_user_function_ex(NULL, + call_user_function(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, - 0, NULL, 0, NULL); + 0, NULL); zval_ptr_dtor(&retval); zval_ptr_dtor(&func_name); @@ -749,11 +749,11 @@ static int php_userstreamop_flush(php_stream *stream) ZVAL_STRINGL(&func_name, USERSTREAM_FLUSH, sizeof(USERSTREAM_FLUSH)-1); - call_result = call_user_function_ex(NULL, + call_result = call_user_function(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, - 0, NULL, 0, NULL); + 0, NULL); if (call_result == SUCCESS && Z_TYPE(retval) != IS_UNDEF && zval_is_true(&retval)) call_result = 0; @@ -816,11 +816,11 @@ static int php_userstreamop_seek(php_stream *stream, zend_off_t offset, int when /* now determine where we are */ ZVAL_STRINGL(&func_name, USERSTREAM_TELL, sizeof(USERSTREAM_TELL)-1); - call_result = call_user_function_ex(NULL, + call_result = call_user_function(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, - 0, NULL, 0, NULL); + 0, NULL); if (call_result == SUCCESS && Z_TYPE(retval) == IS_LONG) { *newoffs = Z_LVAL(retval); @@ -886,11 +886,11 @@ static int php_userstreamop_stat(php_stream *stream, php_stream_statbuf *ssb) ZVAL_STRINGL(&func_name, USERSTREAM_STAT, sizeof(USERSTREAM_STAT)-1); - call_result = call_user_function_ex(NULL, + call_result = call_user_function(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, - 0, NULL, 0, NULL); + 0, NULL); if (call_result == SUCCESS && Z_TYPE(retval) == IS_ARRAY) { if (SUCCESS == statbuf_from_array(&retval, ssb)) @@ -920,7 +920,7 @@ static int php_userstreamop_set_option(php_stream *stream, int option, int value switch (option) { case PHP_STREAM_OPTION_CHECK_LIVENESS: ZVAL_STRINGL(&func_name, USERSTREAM_EOF, sizeof(USERSTREAM_EOF)-1); - call_result = call_user_function_ex(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, 0, NULL, 0, NULL); + call_result = call_user_function(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, 0, NULL); if (call_result == SUCCESS && (Z_TYPE(retval) == IS_FALSE || Z_TYPE(retval) == IS_TRUE)) { ret = zval_is_true(&retval) ? PHP_STREAM_OPTION_RETURN_ERR : PHP_STREAM_OPTION_RETURN_OK; } else { @@ -1412,11 +1412,10 @@ static size_t php_userstreamop_readdir(php_stream *stream, char *buf, size_t cou ZVAL_STRINGL(&func_name, USERSTREAM_DIR_READ, sizeof(USERSTREAM_DIR_READ)-1); - call_result = call_user_function_ex(NULL, + call_result = call_user_function(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, - 0, NULL, 0, NULL); if (call_result == SUCCESS && Z_TYPE(retval) != IS_FALSE && Z_TYPE(retval) != IS_TRUE) { @@ -1445,11 +1444,11 @@ static int php_userstreamop_closedir(php_stream *stream, int close_handle) ZVAL_STRINGL(&func_name, USERSTREAM_DIR_CLOSE, sizeof(USERSTREAM_DIR_CLOSE)-1); - call_user_function_ex(NULL, + call_user_function(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, - 0, NULL, 0, NULL); + 0, NULL); zval_ptr_dtor(&retval); zval_ptr_dtor(&func_name); @@ -1469,11 +1468,11 @@ static int php_userstreamop_rewinddir(php_stream *stream, zend_off_t offset, int ZVAL_STRINGL(&func_name, USERSTREAM_DIR_REWIND, sizeof(USERSTREAM_DIR_REWIND)-1); - call_user_function_ex(NULL, + call_user_function(NULL, Z_ISUNDEF(us->object)? NULL : &us->object, &func_name, &retval, - 0, NULL, 0, NULL); + 0, NULL); zval_ptr_dtor(&retval); zval_ptr_dtor(&func_name); |