com php-src: Merge branch 'PHP-7.1': ext/curl/curl_file.c ext/zip/php_zip.c

From: Date: Mon, 16 Jan 2017 01:33:48 +0000
Subject: com php-src: Merge branch 'PHP-7.1': ext/curl/curl_file.c ext/zip/php_zip.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-96742@lists.php.net to get a copy of this message
Commit: 540e6728683b19ab9b1336650af06b3100422f02 Author: Stanislav Malyshev <stas@php.net> Sun, 15 Jan 2017 17:33:48 -0800 Parents: cd2b462a2742c79256668d4736644e34573c33d9 19e80ef4963d7371ee25b85f8224ee912efe418e Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=540e6728683b19ab9b1336650af06b3100422f02 Log: Merge branch 'PHP-7.1' * PHP-7.1: Update more functions with path check Changed paths: MM ext/curl/curl_file.c MM ext/zip/php_zip.c Diff: diff --cc ext/curl/curl_file.c index c18f365,7a047fe..92378a6 --- a/ext/curl/curl_file.c +++ b/ext/curl/curl_file.c @@@ -31,20 -31,20 +31,20 @@@ PHP_CURL_API zend_class_entry *curl_CUR static void curlfile_ctor(INTERNAL_FUNCTION_PARAMETERS) { - char *fname = NULL, *mime = NULL, *postname = NULL; - size_t fname_len, mime_len, postname_len; + zend_string *fname, *mime = NULL, *postname = NULL; zval *cf = return_value; - if (zend_parse_parameters(ZEND_NUM_ARGS(), "p|ss", &fname, &fname_len, &mime, &mime_len, &postname, &postname_len) == FAILURE) { - return; - } + ZEND_PARSE_PARAMETERS_START(1,3) - Z_PARAM_STR(fname) ++ Z_PARAM_PATH_STR(fname) + Z_PARAM_OPTIONAL + Z_PARAM_STR(mime) + Z_PARAM_STR(postname) + ZEND_PARSE_PARAMETERS_END(); - if (fname) { - zend_update_property_string(curl_CURLFile_class, cf, "name", sizeof("name")-1, fname); - } + zend_update_property_string(curl_CURLFile_class, cf, "name", sizeof("name")-1, ZSTR_VAL(fname)); if (mime) { - zend_update_property_string(curl_CURLFile_class, cf, "mime", sizeof("mime")-1, mime); + zend_update_property_string(curl_CURLFile_class, cf, "mime", sizeof("mime")-1, ZSTR_VAL(mime)); } if (postname) {

« previous php.cvs (#96742) next »