jani                                     Wed, 25 Nov 2009 12:26:10 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=291304

Log:
ws

Changed paths:
    U   php/php-src/branches/PHP_5_2/sapi/apache2handler/sapi_apache2.c
    U   php/php-src/branches/PHP_5_3/sapi/apache2handler/sapi_apache2.c
    U   php/php-src/trunk/sapi/apache2handler/sapi_apache2.c

Modified: php/php-src/branches/PHP_5_2/sapi/apache2handler/sapi_apache2.c
===================================================================
--- php/php-src/branches/PHP_5_2/sapi/apache2handler/sapi_apache2.c	2009-11-25 11:22:03 UTC (rev 291303)
+++ php/php-src/branches/PHP_5_2/sapi/apache2handler/sapi_apache2.c	2009-11-25 12:26:10 UTC (rev 291304)
@@ -99,7 +99,7 @@
 	ptr = val;

 	*val = '\0';
-
+
 	do {
 		val++;
 	} while (*val == ' ');
@@ -115,7 +115,7 @@
 		apr_table_add(ctx->r->headers_out, sapi_header->header, val);
 	}
 	*ptr = ':';
-
+
 	return SAPI_HEADER_ADD;
 }

@@ -136,8 +136,8 @@
 			apr_table_set(ctx->r->subprocess_env, "force-response-1.0", "true");
 		}
 	}
-
-	/*	call ap_set_content_type only once, else each time we call it,
+
+	/*	call ap_set_content_type only once, else each time we call it,
 		configured output filters for that content type will be added */
 	if (!ctx->content_type) {
 		ctx->content_type = sapi_get_default_content_type(TSRMLS_C);
@@ -177,7 +177,7 @@
 		buf += len;
 		len = count_bytes - tlen;
 	}
-
+
 	return tlen;
 }

@@ -223,7 +223,7 @@
 {
 	php_struct *ctx = SG(server_context);
 	const char *env_var;
-
+
 	env_var = apr_table_get(ctx->r->subprocess_env, name);

 	return (char *) env_var;
@@ -301,7 +301,8 @@
 	}
 }

-static time_t php_apache_sapi_get_request_time(TSRMLS_D) {
+static time_t php_apache_sapi_get_request_time(TSRMLS_D)
+{
 	php_struct *ctx = SG(server_context);
 	return apr_time_sec(ctx->r->request_time);
 }
@@ -380,7 +381,7 @@
 	int threaded_mpm;

 	ap_mpm_query(AP_MPMQ_IS_THREADED, &threaded_mpm);
-	if(threaded_mpm) {
+	if (threaded_mpm) {
 		ap_log_error(APLOG_MARK, APLOG_CRIT, 0, 0, "Apache is running a threaded MPM, but your PHP Module is not compiled to be threadsafe.  You need to recompile PHP.");
 		return DONE;
 	}
@@ -484,12 +485,12 @@
 		uint str_len;
 		php_conf_rec *c = ap_get_module_config(r->per_dir_config, &php5_module);

-		for (zend_hash_internal_pointer_reset(&c->config);
-				zend_hash_get_current_key_ex(&c->config, &str, &str_len, NULL, 0,  NULL) == HASH_KEY_IS_STRING;
-				zend_hash_move_forward(&c->config)
+		for (zend_hash_internal_pointer_reset(&c->config);
+			zend_hash_get_current_key_ex(&c->config, &str, &str_len, NULL, 0, NULL) == HASH_KEY_IS_STRING;
+			zend_hash_move_forward(&c->config)
 		) {
 			zend_restore_ini_entry(str, str_len, ZEND_INI_STAGE_SHUTDOWN);
-		}
+		}
 	}
 	if (p) {
 		((php_struct *)SG(server_context))->r = p;
@@ -539,7 +540,7 @@
 	}

 	/* Give a 404 if PATH_INFO is used but is explicitly disabled in
-	 * the configuration; default behaviour is to accept. */
+	 * the configuration; default behaviour is to accept. */
 	if (r->used_path_info == AP_REQ_REJECT_PATH_INFO
 		&& r->path_info && r->path_info[0]) {
 		PHPAP_INI_OFF;
@@ -587,17 +588,17 @@
 		if (!parent_req) {
 			parent_req = ctx->r;
 		}
-		if (parent_req && parent_req->handler &&
-				strcmp(parent_req->handler, PHP_MAGIC_TYPE) &&
-				strcmp(parent_req->handler, PHP_SOURCE_MAGIC_TYPE) &&
+		if (parent_req && parent_req->handler &&
+				strcmp(parent_req->handler, PHP_MAGIC_TYPE) &&
+				strcmp(parent_req->handler, PHP_SOURCE_MAGIC_TYPE) &&
 				strcmp(parent_req->handler, PHP_SCRIPT)) {
 			if (php_apache_request_ctor(r, ctx TSRMLS_CC)!=SUCCESS) {
 				zend_bailout();
 			}
 		}
-
-		/*
-		 * check if comming due to ErrorDocument
+
+		/*
+		 * check if comming due to ErrorDocument
 		 * We make a special exception of 413 (Invalid POST request) as the invalidity of the request occurs
 		 * during processing of the request by PHP during POST processing. Therefor we need to re-use the exiting
 		 * PHP instance to handle the request rather then creating a new one.

Modified: php/php-src/branches/PHP_5_3/sapi/apache2handler/sapi_apache2.c
===================================================================
--- php/php-src/branches/PHP_5_3/sapi/apache2handler/sapi_apache2.c	2009-11-25 11:22:03 UTC (rev 291303)
+++ php/php-src/branches/PHP_5_3/sapi/apache2handler/sapi_apache2.c	2009-11-25 12:26:10 UTC (rev 291304)
@@ -109,7 +109,7 @@
 			ptr = val;

 			*val = '\0';
-
+
 			do {
 				val++;
 			} while (*val == ' ');
@@ -151,8 +151,8 @@
 			apr_table_set(ctx->r->subprocess_env, "force-response-1.0", "true");
 		}
 	}
-
-	/*	call ap_set_content_type only once, else each time we call it,
+
+	/*	call ap_set_content_type only once, else each time we call it,
 		configured output filters for that content type will be added */
 	if (!ctx->content_type) {
 		ctx->content_type = sapi_get_default_content_type(TSRMLS_C);
@@ -192,7 +192,7 @@
 		buf += len;
 		len = count_bytes - tlen;
 	}
-
+
 	return tlen;
 }

@@ -238,7 +238,7 @@
 {
 	php_struct *ctx = SG(server_context);
 	const char *env_var;
-
+
 	env_var = apr_table_get(ctx->r->subprocess_env, name);

 	return (char *) env_var;
@@ -316,7 +316,8 @@
 	}
 }

-static time_t php_apache_sapi_get_request_time(TSRMLS_D) {
+static time_t php_apache_sapi_get_request_time(TSRMLS_D)
+{
 	php_struct *ctx = SG(server_context);
 	return apr_time_sec(ctx->r->request_time);
 }
@@ -500,12 +501,12 @@
 		uint str_len;
 		php_conf_rec *c = ap_get_module_config(r->per_dir_config, &php5_module);

-		for (zend_hash_internal_pointer_reset(&c->config);
-				zend_hash_get_current_key_ex(&c->config, &str, &str_len, NULL, 0,  NULL) == HASH_KEY_IS_STRING;
-				zend_hash_move_forward(&c->config)
+		for (zend_hash_internal_pointer_reset(&c->config);
+			zend_hash_get_current_key_ex(&c->config, &str, &str_len, NULL, 0,  NULL) == HASH_KEY_IS_STRING;
+			zend_hash_move_forward(&c->config)
 		) {
 			zend_restore_ini_entry(str, str_len, ZEND_INI_STAGE_SHUTDOWN);
-		}
+		}
 	}
 	if (p) {
 		((php_struct *)SG(server_context))->r = p;
@@ -555,7 +556,7 @@
 	}

 	/* Give a 404 if PATH_INFO is used but is explicitly disabled in
-	 * the configuration; default behaviour is to accept. */
+	 * the configuration; default behaviour is to accept. */
 	if (r->used_path_info == AP_REQ_REJECT_PATH_INFO
 		&& r->path_info && r->path_info[0]) {
 		PHPAP_INI_OFF;
@@ -603,17 +604,17 @@
 		if (!parent_req) {
 			parent_req = ctx->r;
 		}
-		if (parent_req && parent_req->handler &&
-				strcmp(parent_req->handler, PHP_MAGIC_TYPE) &&
-				strcmp(parent_req->handler, PHP_SOURCE_MAGIC_TYPE) &&
+		if (parent_req && parent_req->handler &&
+				strcmp(parent_req->handler, PHP_MAGIC_TYPE) &&
+				strcmp(parent_req->handler, PHP_SOURCE_MAGIC_TYPE) &&
 				strcmp(parent_req->handler, PHP_SCRIPT)) {
 			if (php_apache_request_ctor(r, ctx TSRMLS_CC)!=SUCCESS) {
 				zend_bailout();
 			}
 		}
-
-		/*
-		 * check if comming due to ErrorDocument
+
+		/*
+		 * check if comming due to ErrorDocument
 		 * We make a special exception of 413 (Invalid POST request) as the invalidity of the request occurs
 		 * during processing of the request by PHP during POST processing. Therefor we need to re-use the exiting
 		 * PHP instance to handle the request rather then creating a new one.

Modified: php/php-src/trunk/sapi/apache2handler/sapi_apache2.c
===================================================================
--- php/php-src/trunk/sapi/apache2handler/sapi_apache2.c	2009-11-25 11:22:03 UTC (rev 291303)
+++ php/php-src/trunk/sapi/apache2handler/sapi_apache2.c	2009-11-25 12:26:10 UTC (rev 291304)
@@ -109,7 +109,7 @@
 			ptr = val;

 			*val = '\0';
-
+
 			do {
 				val++;
 			} while (*val == ' ');
@@ -151,8 +151,8 @@
 			apr_table_set(ctx->r->subprocess_env, "force-response-1.0", "true");
 		}
 	}
-
-	/*	call ap_set_content_type only once, else each time we call it,
+
+	/*	call ap_set_content_type only once, else each time we call it,
 		configured output filters for that content type will be added */
 	if (!ctx->content_type) {
 		ctx->content_type = sapi_get_default_content_type(TSRMLS_C);
@@ -192,7 +192,7 @@
 		buf += len;
 		len = count_bytes - tlen;
 	}
-
+
 	return tlen;
 }

@@ -238,7 +238,7 @@
 {
 	php_struct *ctx = SG(server_context);
 	const char *env_var;
-
+
 	env_var = apr_table_get(ctx->r->subprocess_env, name);

 	return (char *) env_var;
@@ -318,7 +318,8 @@
 	}
 }

-static time_t php_apache_sapi_get_request_time(TSRMLS_D) {
+static time_t php_apache_sapi_get_request_time(TSRMLS_D)
+{
 	php_struct *ctx = SG(server_context);
 	return apr_time_sec(ctx->r->request_time);
 }
@@ -497,12 +498,12 @@
 		uint str_len;
 		php_conf_rec *c = ap_get_module_config(r->per_dir_config, &php6_module);

-		for (zend_hash_internal_pointer_reset(&c->config);
-				zend_hash_get_current_key_ex(&c->config, &str, &str_len, NULL, 0,  NULL) == HASH_KEY_IS_STRING;
-				zend_hash_move_forward(&c->config)
+		for (zend_hash_internal_pointer_reset(&c->config);
+			zend_hash_get_current_key_ex(&c->config, &str, &str_len, NULL, 0,  NULL) == HASH_KEY_IS_STRING;
+			zend_hash_move_forward(&c->config)
 		) {
 			zend_restore_ini_entry(str.s, str_len, ZEND_INI_STAGE_SHUTDOWN);
-		}
+		}
 	}
 	if (p) {
 		((php_struct *)SG(server_context))->r = p;
@@ -552,7 +553,7 @@
 	}

 	/* Give a 404 if PATH_INFO is used but is explicitly disabled in
-	 * the configuration; default behaviour is to accept. */
+	 * the configuration; default behaviour is to accept. */
 	if (r->used_path_info == AP_REQ_REJECT_PATH_INFO
 		&& r->path_info && r->path_info[0]) {
 		PHPAP_INI_OFF;
@@ -600,17 +601,17 @@
 		if (!parent_req) {
 			parent_req = ctx->r;
 		}
-		if (parent_req && parent_req->handler &&
-				strcmp(parent_req->handler, PHP_MAGIC_TYPE) &&
-				strcmp(parent_req->handler, PHP_SOURCE_MAGIC_TYPE) &&
+		if (parent_req && parent_req->handler &&
+				strcmp(parent_req->handler, PHP_MAGIC_TYPE) &&
+				strcmp(parent_req->handler, PHP_SOURCE_MAGIC_TYPE) &&
 				strcmp(parent_req->handler, PHP_SCRIPT)) {
 			if (php_apache_request_ctor(r, ctx TSRMLS_CC)!=SUCCESS) {
 				zend_bailout();
 			}
 		}
-
-		/*
-		 * check if comming due to ErrorDocument
+
+		/*
+		 * check if comming due to ErrorDocument
 		 * We make a special exception of 413 (Invalid POST request) as the invalidity of the request occurs
 		 * during processing of the request by PHP during POST processing. Therefor we need to re-use the exiting
 		 * PHP instance to handle the request rather then creating a new one.
-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to