diff options
| author | Stanislav Malyshev <stas@php.net> | 2015-01-03 01:22:58 -0800 |
|---|---|---|
| committer | Stanislav Malyshev <stas@php.net> | 2015-01-10 15:07:38 -0800 |
| commit | b7a7b1a624c97945c0aaa49d46ae996fc0bdb6bc (patch) | |
| tree | 0e09490075ee4f9a75a77ef4168d8ee254c52e5b /sapi/apache2handler | |
| parent | 773c8b0c092a0e9ad5c5548815bcb9991d54d5c1 (diff) | |
| download | php-git-b7a7b1a624c97945c0aaa49d46ae996fc0bdb6bc.tar.gz | |
trailing whitespace removal
Diffstat (limited to 'sapi/apache2handler')
| -rw-r--r-- | sapi/apache2handler/apache_config.c | 12 | ||||
| -rw-r--r-- | sapi/apache2handler/php_functions.c | 48 |
2 files changed, 30 insertions, 30 deletions
diff --git a/sapi/apache2handler/apache_config.c b/sapi/apache2handler/apache_config.c index 92a683b22c..e1644d647d 100644 --- a/sapi/apache2handler/apache_config.c +++ b/sapi/apache2handler/apache_config.c @@ -60,11 +60,11 @@ static const char *real_value_hnd(cmd_parms *cmd, void *dummy, const char *name, php_dir_entry e; phpapdebug((stderr, "Getting %s=%s for %p (%d)\n", name, value, dummy, zend_hash_num_elements(&d->config))); - + if (!strncasecmp(value, "none", sizeof("none"))) { value = ""; } - + e.value = apr_pstrdup(cmd->pool, value); e.value_len = strlen(value); e.status = status; @@ -157,7 +157,7 @@ void *merge_php_config(apr_pool_t *p, void *base_conf, void *new_conf) //??? zend_hash_merge_ex(&n->config, &e->config, NULL, sizeof(php_dir_entry), (merge_checker_func_t) should_overwrite_per_dir_entry, NULL); #if STAS_0 for (zend_hash_internal_pointer_reset(&d->config); - zend_hash_get_current_key(&d->config, &str, &str_len, + zend_hash_get_current_key(&d->config, &str, &str_len, &num_index) == HASH_KEY_IS_STRING; zend_hash_move_forward(&d->config)) { pe = NULL; @@ -176,7 +176,7 @@ char *get_php_config(void *conf, char *name, size_t name_len) { php_conf_rec *d = conf; php_dir_entry *pe; - + if ((pe = zend_hash_str_find_ptr(&d->config, name, name_len)) != NULL) { return pe->value; } @@ -189,7 +189,7 @@ void apply_config(void *dummy) php_conf_rec *d = dummy; zend_string *str; php_dir_entry *data; - + ZEND_HASH_FOREACH_STR_KEY_PTR(&d->config, str, data) { phpapdebug((stderr, "APPLYING (%s)(%s)\n", str, data->value)); if (zend_alter_ini_entry_chars(str, data->value, data->value_len, data->status, data->htaccess?PHP_INI_STAGE_HTACCESS:PHP_INI_STAGE_ACTIVATE) == FAILURE) { @@ -212,7 +212,7 @@ static apr_status_t destroy_php_config(void *data) { php_conf_rec *d = data; - phpapdebug((stderr, "Destroying config %p\n", data)); + phpapdebug((stderr, "Destroying config %p\n", data)); zend_hash_destroy(&d->config); return APR_SUCCESS; diff --git a/sapi/apache2handler/php_functions.c b/sapi/apache2handler/php_functions.c index 2eb6a64c00..fd4edb2bb8 100644 --- a/sapi/apache2handler/php_functions.c +++ b/sapi/apache2handler/php_functions.c @@ -59,7 +59,7 @@ php_apache2_info_struct php_apache2_info; static request_rec *php_apache_lookup_uri(char *filename) { php_struct *ctx = SG(server_context); - + if (!filename || !ctx || !ctx->r) { return NULL; } @@ -129,7 +129,7 @@ PHP_FUNCTION(apache_lookup_uri) php_error_docref(NULL, E_WARNING, "Unable to include '%s' - URI lookup failed", filename); RETURN_FALSE; } - + if (rr->status == HTTP_OK) { object_init(return_value); @@ -162,7 +162,7 @@ PHP_FUNCTION(apache_lookup_uri) ap_destroy_sub_req(rr); return; } - + php_error_docref(NULL, E_WARNING, "Unable to include '%s' - error finding URI", filename); ap_destroy_sub_req(rr); RETURN_FALSE; @@ -181,7 +181,7 @@ PHP_FUNCTION(apache_request_headers) } array_init(return_value); - + ctx = SG(server_context); arr = apr_table_elts(ctx->r->headers_in); @@ -205,7 +205,7 @@ PHP_FUNCTION(apache_response_headers) } array_init(return_value); - + ctx = SG(server_context); arr = apr_table_elts(ctx->r->headers_out); @@ -349,9 +349,9 @@ PHP_FUNCTION(apache_get_modules) { int n; char *p; - + array_init(return_value); - + for (n = 0; ap_loaded_modules[n]; ++n) { char *s = (char *) ap_loaded_modules[n]->name; if ((p = strchr(s, '.'))) { @@ -378,7 +378,7 @@ PHP_MINFO_FUNCTION(apache) AP_DECLARE_DATA extern unixd_config_rec unixd_config; #endif #endif - + for (n = 0; ap_loaded_modules[n]; ++n) { char *s = (char *) ap_loaded_modules[n]->name; if ((p = strchr(s, '.'))) { @@ -395,21 +395,21 @@ PHP_MINFO_FUNCTION(apache) tmp1.s->val[0] = '\0'; } } - + php_info_print_table_start(); if (apv && *apv) { php_info_print_table_row(2, "Apache Version", apv); } snprintf(tmp, sizeof(tmp), "%d", MODULE_MAGIC_NUMBER); php_info_print_table_row(2, "Apache API Version", tmp); - + if (serv->server_admin && *(serv->server_admin)) { php_info_print_table_row(2, "Server Administrator", serv->server_admin); } - + snprintf(tmp, sizeof(tmp), "%s:%u", serv->server_hostname, serv->port); php_info_print_table_row(2, "Hostname:Port", tmp); - + #if !defined(WIN32) && !defined(WINNT) && !defined(NETWARE) #if MODULE_MAGIC_NUMBER_MAJOR >= 20081201 snprintf(tmp, sizeof(tmp), "%s(%d)/%d", ap_unixd_config.user_name, ap_unixd_config.user_id, ap_unixd_config.group_id); @@ -424,25 +424,25 @@ PHP_MINFO_FUNCTION(apache) php_info_print_table_row(2, "Max Requests", tmp); apr_snprintf(tmp, sizeof tmp, - "Connection: %" APR_TIME_T_FMT " - Keep-Alive: %" APR_TIME_T_FMT, + "Connection: %" APR_TIME_T_FMT " - Keep-Alive: %" APR_TIME_T_FMT, apr_time_sec(serv->timeout), apr_time_sec(serv->keep_alive_timeout)); php_info_print_table_row(2, "Timeouts", tmp); - + php_info_print_table_row(2, "Virtual Server", (serv->is_virtual ? "Yes" : "No")); php_info_print_table_row(2, "Server Root", ap_server_root); php_info_print_table_row(2, "Loaded Modules", tmp1.s->val); smart_str_free(&tmp1); php_info_print_table_end(); - + DISPLAY_INI_ENTRIES(); { const apr_array_header_t *arr = apr_table_elts(((php_struct *) SG(server_context))->r->subprocess_env); char *key, *val; - + SECTION("Apache Environment"); - php_info_print_table_start(); + php_info_print_table_start(); php_info_print_table_header(2, "Variable", "Value"); APR_ARRAY_FOREACH_OPEN(arr, key, val) if (!val) { @@ -450,14 +450,14 @@ PHP_MINFO_FUNCTION(apache) } php_info_print_table_row(2, key, val); APR_ARRAY_FOREACH_CLOSE() - - php_info_print_table_end(); - + + php_info_print_table_end(); + SECTION("HTTP Headers Information"); php_info_print_table_start(); php_info_print_table_colspan_header(2, "HTTP Request Headers"); php_info_print_table_row(2, "HTTP Request", ((php_struct *) SG(server_context))->r->the_request); - + arr = apr_table_elts(((php_struct *) SG(server_context))->r->headers_in); APR_ARRAY_FOREACH_OPEN(arr, key, val) if (!val) { @@ -474,7 +474,7 @@ PHP_MINFO_FUNCTION(apache) } php_info_print_table_row(2, key, val); APR_ARRAY_FOREACH_CLOSE() - + php_info_print_table_end(); } } @@ -519,7 +519,7 @@ ZEND_END_ARG_INFO() static const zend_function_entry apache_functions[] = { PHP_FE(apache_lookup_uri, arginfo_apache2handler_lookup_uri) - PHP_FE(virtual, arginfo_apache2handler_virtual) + PHP_FE(virtual, arginfo_apache2handler_virtual) PHP_FE(apache_request_headers, arginfo_apache2handler_getallheaders) PHP_FE(apache_response_headers, arginfo_apache2handler_response_headers) PHP_FE(apache_setenv, arginfo_apache2handler_setenv) @@ -559,7 +559,7 @@ zend_module_entry php_apache_module = { PHP_MINIT(apache), PHP_MSHUTDOWN(apache), NULL, - NULL, + NULL, PHP_MINFO(apache), NULL, STANDARD_MODULE_PROPERTIES |
