Permalink
Browse files

added trailing newlines to ndk.c and ndk_upstream_list.c because they…

… cause compilation errors (-Werror) on RHEL 5.2. also removed several spots of line trailing spaces.
  • Loading branch information...
1 parent d2f1c55 commit bc97eea6d900013a8cd26b1117491dc513450d27 @agentzh agentzh committed Mar 8, 2011
Showing with 15 additions and 13 deletions.
  1. +7 −6 src/ndk.c
  2. +8 −7 src/ndk_upstream_list.c
View
13 src/ndk.c
@@ -1,4 +1,4 @@
-
+
/*
* 2010 (C) Marcus Clyne
*/
@@ -52,7 +52,7 @@ static void ndk_http_exit_master (ngx_cycle_t *cycle);
ngx_http_module_t ndk_http_module_ctx = {
-
+
#if (NDK_HTTP_PRE_CONFIG)
ndk_http_preconfiguration,
#else
@@ -125,7 +125,7 @@ ngx_module_t ndk_http_module = {
NULL, // init thread
NULL, // exit thread
-
+
#if (NDK_HTTP_EXIT_PROCESS)
ndk_http_exit_process,
#else
@@ -146,9 +146,10 @@ static void *
ndk_http_create_main_conf (ngx_conf_t *cf)
{
ndk_http_main_conf_t *mcf;
-
+
ndk_pcallocp_rce (mcf, cf->pool);
-
+
return mcf;
}
-#endif
+#endif
+
View
15 src/ndk_upstream_list.c
@@ -69,7 +69,7 @@ ndk_upstream_list (ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
ndk_http_main_conf_t *mcf;
mcf = ngx_http_conf_get_module_main_conf (cf, ndk_http_module);
-
+
ula = mcf->upstreams;
// create array of upstream lists it doesn't already exist
@@ -94,7 +94,7 @@ ndk_upstream_list (ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
for ( ; ul<ule; ul++) {
- if (ul->name.len == value->len &&
+ if (ul->name.len == value->len &&
ngx_strncasecmp (ul->name.data, value->data, value->len) == 0) {
ngx_conf_log_error (NGX_LOG_EMERG, cf, 0,
@@ -148,7 +148,7 @@ ndk_upstream_list (ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
bucket = ngx_palloc (cf->pool, buckets * sizeof (ngx_str_t **));
if (bucket == NULL)
return NGX_CONF_ERROR;
-
+
ul->elts = bucket;
ul->nelts = buckets;
@@ -177,15 +177,15 @@ ndk_upstream_list (ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
}
return NGX_CONF_OK;
-}
+}
ndk_upstream_list_t *
ndk_get_upstream_list (ndk_http_main_conf_t *mcf, u_char *data, size_t len)
{
- ndk_upstream_list_t *ul, *ule;
+ ndk_upstream_list_t *ul, *ule;
ngx_array_t *ua = mcf->upstreams;
-
+
if (ua == NULL) {
return NULL;
}
@@ -201,4 +201,5 @@ ndk_get_upstream_list (ndk_http_main_conf_t *mcf, u_char *data, size_t len)
}
return NULL;
-}
+}
+

0 comments on commit bc97eea

Please sign in to comment.