aboutsummaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
Diffstat (limited to 'src/core')
-rw-r--r--src/core/ngx_conf_file.c6
-rw-r--r--src/core/ngx_connection.c36
-rw-r--r--src/core/ngx_connection.h22
-rw-r--r--src/core/ngx_crypt.c4
-rw-r--r--src/core/ngx_cycle.h40
-rw-r--r--src/core/ngx_file.c2
-rw-r--r--src/core/ngx_inet.c20
-rw-r--r--src/core/ngx_log.c20
-rw-r--r--src/core/ngx_parse_time.c2
-rw-r--r--src/core/ngx_slab.c8
-rw-r--r--src/core/ngx_syslog.c6
11 files changed, 83 insertions, 83 deletions
diff --git a/src/core/ngx_conf_file.c b/src/core/ngx_conf_file.c
index fb72656ff..c60d5fb41 100644
--- a/src/core/ngx_conf_file.c
+++ b/src/core/ngx_conf_file.c
@@ -613,9 +613,9 @@ ngx_conf_read_token(ngx_conf_t *cf)
need_space = 0;
} else {
- ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
- "unexpected \"%c\"", ch);
- return NGX_ERROR;
+ ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
+ "unexpected \"%c\"", ch);
+ return NGX_ERROR;
}
}
diff --git a/src/core/ngx_connection.c b/src/core/ngx_connection.c
index 572def263..5a53bac31 100644
--- a/src/core/ngx_connection.c
+++ b/src/core/ngx_connection.c
@@ -47,21 +47,21 @@ ngx_create_listening(ngx_conf_t *cf, void *sockaddr, socklen_t socklen)
switch (ls->sockaddr->sa_family) {
#if (NGX_HAVE_INET6)
case AF_INET6:
- ls->addr_text_max_len = NGX_INET6_ADDRSTRLEN;
- break;
+ ls->addr_text_max_len = NGX_INET6_ADDRSTRLEN;
+ break;
#endif
#if (NGX_HAVE_UNIX_DOMAIN)
case AF_UNIX:
- ls->addr_text_max_len = NGX_UNIX_ADDRSTRLEN;
- len++;
- break;
+ ls->addr_text_max_len = NGX_UNIX_ADDRSTRLEN;
+ len++;
+ break;
#endif
case AF_INET:
- ls->addr_text_max_len = NGX_INET_ADDRSTRLEN;
- break;
+ ls->addr_text_max_len = NGX_INET_ADDRSTRLEN;
+ break;
default:
- ls->addr_text_max_len = NGX_SOCKADDR_STRLEN;
- break;
+ ls->addr_text_max_len = NGX_SOCKADDR_STRLEN;
+ break;
}
ls->addr_text.data = ngx_pnalloc(cf->pool, len);
@@ -168,22 +168,22 @@ ngx_set_inherited_sockets(ngx_cycle_t *cycle)
#if (NGX_HAVE_INET6)
case AF_INET6:
- ls[i].addr_text_max_len = NGX_INET6_ADDRSTRLEN;
- len = NGX_INET6_ADDRSTRLEN + sizeof("[]:65535") - 1;
- break;
+ ls[i].addr_text_max_len = NGX_INET6_ADDRSTRLEN;
+ len = NGX_INET6_ADDRSTRLEN + sizeof("[]:65535") - 1;
+ break;
#endif
#if (NGX_HAVE_UNIX_DOMAIN)
case AF_UNIX:
- ls[i].addr_text_max_len = NGX_UNIX_ADDRSTRLEN;
- len = NGX_UNIX_ADDRSTRLEN;
- break;
+ ls[i].addr_text_max_len = NGX_UNIX_ADDRSTRLEN;
+ len = NGX_UNIX_ADDRSTRLEN;
+ break;
#endif
case AF_INET:
- ls[i].addr_text_max_len = NGX_INET_ADDRSTRLEN;
- len = NGX_INET_ADDRSTRLEN + sizeof(":65535") - 1;
- break;
+ ls[i].addr_text_max_len = NGX_INET_ADDRSTRLEN;
+ len = NGX_INET_ADDRSTRLEN + sizeof(":65535") - 1;
+ break;
default:
ngx_log_error(NGX_LOG_CRIT, cycle->log, ngx_socket_errno,
diff --git a/src/core/ngx_connection.h b/src/core/ngx_connection.h
index 19a2ab787..b0d162ae0 100644
--- a/src/core/ngx_connection.h
+++ b/src/core/ngx_connection.h
@@ -95,25 +95,25 @@ struct ngx_listening_s {
typedef enum {
- NGX_ERROR_ALERT = 0,
- NGX_ERROR_ERR,
- NGX_ERROR_INFO,
- NGX_ERROR_IGNORE_ECONNRESET,
- NGX_ERROR_IGNORE_EINVAL
+ NGX_ERROR_ALERT = 0,
+ NGX_ERROR_ERR,
+ NGX_ERROR_INFO,
+ NGX_ERROR_IGNORE_ECONNRESET,
+ NGX_ERROR_IGNORE_EINVAL
} ngx_connection_log_error_e;
typedef enum {
- NGX_TCP_NODELAY_UNSET = 0,
- NGX_TCP_NODELAY_SET,
- NGX_TCP_NODELAY_DISABLED
+ NGX_TCP_NODELAY_UNSET = 0,
+ NGX_TCP_NODELAY_SET,
+ NGX_TCP_NODELAY_DISABLED
} ngx_connection_tcp_nodelay_e;
typedef enum {
- NGX_TCP_NOPUSH_UNSET = 0,
- NGX_TCP_NOPUSH_SET,
- NGX_TCP_NOPUSH_DISABLED
+ NGX_TCP_NOPUSH_UNSET = 0,
+ NGX_TCP_NOPUSH_SET,
+ NGX_TCP_NOPUSH_DISABLED
} ngx_connection_tcp_nopush_e;
diff --git a/src/core/ngx_crypt.c b/src/core/ngx_crypt.c
index d7d068c6a..9db74f49b 100644
--- a/src/core/ngx_crypt.c
+++ b/src/core/ngx_crypt.c
@@ -165,8 +165,8 @@ ngx_crypt_to64(u_char *p, uint32_t v, size_t n)
"./0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
while (n--) {
- *p++ = itoa64[v & 0x3f];
- v >>= 6;
+ *p++ = itoa64[v & 0x3f];
+ v >>= 6;
}
return p;
diff --git a/src/core/ngx_cycle.h b/src/core/ngx_cycle.h
index cfdbb550e..c51b7ff3b 100644
--- a/src/core/ngx_cycle.h
+++ b/src/core/ngx_cycle.h
@@ -79,35 +79,35 @@ struct ngx_cycle_s {
typedef struct {
- ngx_flag_t daemon;
- ngx_flag_t master;
+ ngx_flag_t daemon;
+ ngx_flag_t master;
- ngx_msec_t timer_resolution;
+ ngx_msec_t timer_resolution;
- ngx_int_t worker_processes;
- ngx_int_t debug_points;
+ ngx_int_t worker_processes;
+ ngx_int_t debug_points;
- ngx_int_t rlimit_nofile;
- off_t rlimit_core;
+ ngx_int_t rlimit_nofile;
+ off_t rlimit_core;
- int priority;
+ int priority;
- ngx_uint_t cpu_affinity_auto;
- ngx_uint_t cpu_affinity_n;
- ngx_cpuset_t *cpu_affinity;
+ ngx_uint_t cpu_affinity_auto;
+ ngx_uint_t cpu_affinity_n;
+ ngx_cpuset_t *cpu_affinity;
- char *username;
- ngx_uid_t user;
- ngx_gid_t group;
+ char *username;
+ ngx_uid_t user;
+ ngx_gid_t group;
- ngx_str_t working_directory;
- ngx_str_t lock_file;
+ ngx_str_t working_directory;
+ ngx_str_t lock_file;
- ngx_str_t pid;
- ngx_str_t oldpid;
+ ngx_str_t pid;
+ ngx_str_t oldpid;
- ngx_array_t env;
- char **environment;
+ ngx_array_t env;
+ char **environment;
} ngx_core_conf_t;
diff --git a/src/core/ngx_file.c b/src/core/ngx_file.c
index d3e2ecebf..6c16e2056 100644
--- a/src/core/ngx_file.c
+++ b/src/core/ngx_file.c
@@ -155,7 +155,7 @@ ngx_create_temp_file(ngx_file_t *file, ngx_path_t *path, ngx_pool_t *pool,
#if 0
for (i = 0; i < file->name.len; i++) {
- file->name.data[i] = 'X';
+ file->name.data[i] = 'X';
}
#endif
diff --git a/src/core/ngx_inet.c b/src/core/ngx_inet.c
index 3bbadb8b8..765bda53d 100644
--- a/src/core/ngx_inet.c
+++ b/src/core/ngx_inet.c
@@ -1242,19 +1242,19 @@ ngx_cmp_sockaddr(struct sockaddr *sa1, socklen_t slen1,
#if (NGX_HAVE_UNIX_DOMAIN)
case AF_UNIX:
- /* TODO length */
+ /* TODO length */
- saun1 = (struct sockaddr_un *) sa1;
- saun2 = (struct sockaddr_un *) sa2;
+ saun1 = (struct sockaddr_un *) sa1;
+ saun2 = (struct sockaddr_un *) sa2;
- if (ngx_memcmp(&saun1->sun_path, &saun2->sun_path,
- sizeof(saun1->sun_path))
- != 0)
- {
- return NGX_DECLINED;
- }
+ if (ngx_memcmp(&saun1->sun_path, &saun2->sun_path,
+ sizeof(saun1->sun_path))
+ != 0)
+ {
+ return NGX_DECLINED;
+ }
- break;
+ break;
#endif
default: /* AF_INET */
diff --git a/src/core/ngx_log.c b/src/core/ngx_log.c
index 08938715d..e7200795a 100644
--- a/src/core/ngx_log.c
+++ b/src/core/ngx_log.c
@@ -33,14 +33,14 @@ typedef struct {
static ngx_command_t ngx_errlog_commands[] = {
- {ngx_string("error_log"),
- NGX_MAIN_CONF|NGX_CONF_1MORE,
- ngx_error_log,
- 0,
- 0,
- NULL},
-
- ngx_null_command
+ { ngx_string("error_log"),
+ NGX_MAIN_CONF|NGX_CONF_1MORE,
+ ngx_error_log,
+ 0,
+ 0,
+ NULL },
+
+ ngx_null_command
};
@@ -585,7 +585,7 @@ ngx_log_set_log(ngx_conf_t *cf, ngx_log_t **head)
return NGX_CONF_ERROR;
}
- } else if (ngx_strncmp(value[1].data, "memory:", 7) == 0) {
+ } else if (ngx_strncmp(value[1].data, "memory:", 7) == 0) {
#if (NGX_DEBUG)
size_t size, needed;
@@ -644,7 +644,7 @@ ngx_log_set_log(ngx_conf_t *cf, ngx_log_t **head)
return NGX_CONF_ERROR;
#endif
- } else if (ngx_strncmp(value[1].data, "syslog:", 7) == 0) {
+ } else if (ngx_strncmp(value[1].data, "syslog:", 7) == 0) {
peer = ngx_pcalloc(cf->pool, sizeof(ngx_syslog_peer_t));
if (peer == NULL) {
return NGX_CONF_ERROR;
diff --git a/src/core/ngx_parse_time.c b/src/core/ngx_parse_time.c
index 831cc71bf..13afde363 100644
--- a/src/core/ngx_parse_time.c
+++ b/src/core/ngx_parse_time.c
@@ -220,7 +220,7 @@ ngx_parse_http_time(u_char *value, size_t len)
}
if (hour > 23 || min > 59 || sec > 59) {
- return NGX_ERROR;
+ return NGX_ERROR;
}
if (day == 29 && month == 1) {
diff --git a/src/core/ngx_slab.c b/src/core/ngx_slab.c
index c1125062a..fa2a64637 100644
--- a/src/core/ngx_slab.c
+++ b/src/core/ngx_slab.c
@@ -222,11 +222,11 @@ ngx_slab_alloc_locked(ngx_slab_pool_t *pool, size_t size)
if (bitmap[n] == NGX_SLAB_BUSY) {
for (n = n + 1; n < map; n++) {
- if (bitmap[n] != NGX_SLAB_BUSY) {
- p = (uintptr_t) bitmap + i;
+ if (bitmap[n] != NGX_SLAB_BUSY) {
+ p = (uintptr_t) bitmap + i;
- goto done;
- }
+ goto done;
+ }
}
prev = (ngx_slab_page_t *)
diff --git a/src/core/ngx_syslog.c b/src/core/ngx_syslog.c
index 08f4c0483..0a67928e0 100644
--- a/src/core/ngx_syslog.c
+++ b/src/core/ngx_syslog.c
@@ -10,9 +10,9 @@
#define NGX_SYSLOG_MAX_STR \
- NGX_MAX_ERROR_STR + sizeof("<255>Jan 01 00:00:00 ") - 1 \
- + (NGX_MAXHOSTNAMELEN - 1) + 1 /* space */ \
- + 32 /* tag */ + 2 /* colon, space */
+ NGX_MAX_ERROR_STR + sizeof("<255>Jan 01 00:00:00 ") - 1 \
+ + (NGX_MAXHOSTNAMELEN - 1) + 1 /* space */ \
+ + 32 /* tag */ + 2 /* colon, space */
static char *ngx_syslog_parse_args(ngx_conf_t *cf, ngx_syslog_peer_t *peer);