com php-src: Merge branch 'PHP-5.6': sapi/cli/php_cli_serve r.c sapi/cli/tests/bug61977.phpt
| From: | Adam Harvey | Date: | Tue, 06 Jan 2015 01:29:40 +0000 |
| Subject: | com php-src: Merge branch 'PHP-5.6': sapi/cli/php_cli_serve r.c sapi/cli/tests/bug61977.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-84005@lists.php.net to get a copy of this message | ||
Commit: a607a1db1d16f62feac06c136c1bf435c3e55a9d
Author: Adam Harvey <aharvey@php.net> Tue, 6 Jan 2015 01:29:40 +0000
Parents: bb7ceb046eb5f0d5fa25066a3d7f9b4eb8cc3c93 27ff425b78a1355a24d44eb719291ebd9022bc87
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=a607a1db1d16f62feac06c136c1bf435c3e55a9d
Log:
Merge branch 'PHP-5.6'
* PHP-5.6:
Handle NULL strings in sapi_cli_server_register_variable().
Allow CLI server test scripts to specify the name of the router file.
Conflicts:
sapi/cli/php_cli_server.c
Changed paths:
MM sapi/cli/php_cli_server.c
MM sapi/cli/tests/bug61977.phpt
Diff:
diff --cc sapi/cli/php_cli_server.c
index 143d433,8bfe677..f46b576
--- a/sapi/cli/php_cli_server.c
+++ b/sapi/cli/php_cli_server.c
@@@ -584,12 -704,17 +584,17 @@@ static size_t sapi_cli_server_read_post
return 0;
} /* }}} */
-static void sapi_cli_server_register_variable(zval *track_vars_array, const char *key, const char
*val TSRMLS_DC) /* {{{ */
+static void sapi_cli_server_register_variable(zval *track_vars_array, const char *key, const char
*val) /* {{{ */
{
char *new_val = (char *)val;
- uint new_val_len;
+ size_t new_val_len;
+
+ if (NULL == val) {
+ return;
+ }
+
- if (sapi_module.input_filter(PARSE_SERVER, (char*)key, &new_val, strlen(val),
&new_val_len TSRMLS_CC)) {
- php_register_variable_safe((char *)key, new_val, new_val_len, track_vars_array TSRMLS_CC);
+ if (sapi_module.input_filter(PARSE_SERVER, (char*)key, &new_val, strlen(val),
&new_val_len)) {
+ php_register_variable_safe((char *)key, new_val, new_val_len, track_vars_array);
}
} /* }}} */