You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2018/09/12 07:13:03 UTC
svn commit: r1840629 - in /tomcat/jk/trunk/native: apache-2.0/mod_jk.c
common/jk_util.c common/jk_util.h iis/jk_isapi_plugin.c
Author: markt
Date: Wed Sep 12 07:13:03 2018
New Revision: 1840629
URL: http://svn.apache.org/viewvc?rev=1840629&view=rev
Log:
Tab police
Modified:
tomcat/jk/trunk/native/apache-2.0/mod_jk.c
tomcat/jk/trunk/native/common/jk_util.c
tomcat/jk/trunk/native/common/jk_util.h
tomcat/jk/trunk/native/iis/jk_isapi_plugin.c
Modified: tomcat/jk/trunk/native/apache-2.0/mod_jk.c
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/apache-2.0/mod_jk.c?rev=1840629&r1=1840628&r2=1840629&view=diff
==============================================================================
--- tomcat/jk/trunk/native/apache-2.0/mod_jk.c (original)
+++ tomcat/jk/trunk/native/apache-2.0/mod_jk.c Wed Sep 12 07:13:03 2018
@@ -2793,7 +2793,7 @@ static int jk_handler(request_rec * r)
clean_uri = apr_pstrdup(r->pool, r->uri);
rc = jk_servlet_normalize(clean_uri, xconf->log);
if (rc != 0) {
- return HTTP_BAD_REQUEST;
+ return HTTP_BAD_REQUEST;
}
worker_name = map_uri_to_worker_ext(xconf->uw_map, clean_uri,
@@ -3810,7 +3810,7 @@ static int jk_translate(request_rec * r)
clean_uri = apr_pstrdup(r->pool, r->uri);
rc = jk_servlet_normalize(clean_uri, conf->log);
if (rc != 0) {
- return HTTP_BAD_REQUEST;
+ return HTTP_BAD_REQUEST;
}
/* Special case to make sure that apache can serve a directory
@@ -4022,7 +4022,7 @@ static int jk_map_to_storage(request_rec
clean_uri = apr_pstrdup(r->pool, r->uri);
rc = jk_servlet_normalize(clean_uri, conf->log);
if (rc != 0) {
- return HTTP_BAD_REQUEST;
+ return HTTP_BAD_REQUEST;
}
if (!conf->uw_map) {
@@ -4061,10 +4061,10 @@ static int jk_map_to_storage(request_rec
if (conf->strip_session == JK_TRUE && conf->strip_session_name) {
char *jsessionid;
if (r->uri) {
- jk_strip_session_id(r->uri, conf->strip_session_name, conf->log);
+ jk_strip_session_id(r->uri, conf->strip_session_name, conf->log);
}
if (r->filename) {
- jk_strip_session_id(r->filename, conf->strip_session_name, conf->log);
+ jk_strip_session_id(r->filename, conf->strip_session_name, conf->log);
}
return DECLINED;
}
Modified: tomcat/jk/trunk/native/common/jk_util.c
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/common/jk_util.c?rev=1840629&r1=1840628&r2=1840629&view=diff
==============================================================================
--- tomcat/jk/trunk/native/common/jk_util.c (original)
+++ tomcat/jk/trunk/native/common/jk_util.c Wed Sep 12 07:13:03 2018
@@ -2182,7 +2182,7 @@ int jk_servlet_normalize(char *path, jk_
int l, w;
if (JK_IS_DEBUG_LEVEL(logger)) {
- jk_log(logger, JK_LOG_DEBUG, "URI on entering jk_servlet_normalize: [%s]", path);
+ jk_log(logger, JK_LOG_DEBUG, "URI on entering jk_servlet_normalize: [%s]", path);
}
// This test allows the loops below to start at index 1 rather than 0.
@@ -2276,7 +2276,7 @@ int jk_servlet_normalize(char *path, jk_
path[w] = '\0';
if (JK_IS_DEBUG_LEVEL(logger)) {
- jk_log(logger, JK_LOG_DEBUG, "URI on exiting jk_servlet_normalize: [%s]", path);
+ jk_log(logger, JK_LOG_DEBUG, "URI on exiting jk_servlet_normalize: [%s]", path);
}
return 0;
@@ -2284,40 +2284,40 @@ int jk_servlet_normalize(char *path, jk_
int jk_strip_session_id(char* path, char* session_name, jk_logger_t *logger) {
- char *jsessionid;
+ char *jsessionid;
jsessionid = strstr(path, session_name);
if (jsessionid) {
- int i;
- int j;
+ int i;
+ int j;
if (JK_IS_DEBUG_LEVEL(logger)) {
jk_log(logger, JK_LOG_DEBUG,
- "removing session identifier for non servlet uri [%s]", path);
+ "removing session identifier for non servlet uri [%s]", path);
}
- // Found a session path parameter.
- // Need to skip at least as many characters as there are in
- // strip_session_name
- i = (int) strlen(session_name);
- j = 0;
- // Increment i until the first character after the parameter
- while (jsessionid[i] != '\0' && jsessionid[i] != ';' && jsessionid[i] != '/') {
- i++;
- }
- // Copy until the end
- while (jsessionid[i] != '\0') {
- jsessionid[j++] = jsessionid[i++];
- }
- // Terminate
- jsessionid[j] = '\0';
+ // Found a session path parameter.
+ // Need to skip at least as many characters as there are in
+ // strip_session_name
+ i = (int) strlen(session_name);
+ j = 0;
+ // Increment i until the first character after the parameter
+ while (jsessionid[i] != '\0' && jsessionid[i] != ';' && jsessionid[i] != '/') {
+ i++;
+ }
+ // Copy until the end
+ while (jsessionid[i] != '\0') {
+ jsessionid[j++] = jsessionid[i++];
+ }
+ // Terminate
+ jsessionid[j] = '\0';
if (JK_IS_DEBUG_LEVEL(logger)) {
jk_log(logger, JK_LOG_DEBUG,
- "result of removing session identifier for non servlet uri is [%s]", path);
+ "result of removing session identifier for non servlet uri is [%s]", path);
}
return 1;
}
- return 0;
+ return 0;
}
#ifdef _MT_CODE_PTHREAD
Modified: tomcat/jk/trunk/native/common/jk_util.h
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/common/jk_util.h?rev=1840629&r1=1840628&r2=1840629&view=diff
==============================================================================
--- tomcat/jk/trunk/native/common/jk_util.h (original)
+++ tomcat/jk/trunk/native/common/jk_util.h Wed Sep 12 07:13:03 2018
@@ -252,8 +252,8 @@ int jk_servlet_normalize(char *path, jk_
int jk_strip_session_id(char* path, char* session_name, jk_logger_t *logger);
-#define JK_NORMALIZE_BAD_PATH -1
-#define JK_NORMALIZE_TRAVERSAL -2
+#define JK_NORMALIZE_BAD_PATH -1
+#define JK_NORMALIZE_TRAVERSAL -2
#define TC32_BRIDGE_TYPE 32
#define TC33_BRIDGE_TYPE 33
Modified: tomcat/jk/trunk/native/iis/jk_isapi_plugin.c
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/iis/jk_isapi_plugin.c?rev=1840629&r1=1840628&r2=1840629&view=diff
==============================================================================
--- tomcat/jk/trunk/native/iis/jk_isapi_plugin.c (original)
+++ tomcat/jk/trunk/native/iis/jk_isapi_plugin.c Wed Sep 12 07:13:03 2018
@@ -2077,7 +2077,7 @@ DWORD WINAPI HttpExtensionProc(LPEXTENSI
lpEcb->ServerSupportFunction(lpEcb->ConnID, HSE_REQ_SET_FLUSH_FLAG,
(LPVOID) TRUE, NULL, NULL);
}
-
+
if (init_ws_service(&private_data, &s, &worker_name)) {
jk_endpoint_t *e = NULL;
jk_worker_t *worker = wc_get_worker_for_name(worker_name, logger);
@@ -2829,8 +2829,8 @@ static int read_registry_init_data(void)
}
}
if (get_config_parameter(src, COLLAPSE_SLASHES_TAG, tmpbuf, sizeof(tmpbuf))) {
- jk_log(logger, JK_LOG_ERROR, "Configuration item '" COLLAPSE_SLASHES_TAG
- "' is deprecated and will be ignored");
+ jk_log(logger, JK_LOG_ERROR, "Configuration item '" COLLAPSE_SLASHES_TAG
+ "' is deprecated and will be ignored");
}
shm_config_size = get_config_int(src, SHM_SIZE_TAG, -1);
worker_mount_reload = get_config_int(src, WORKER_MOUNT_RELOAD_TAG, JK_URIMAP_DEF_RELOAD);
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org