diff options
author | Alejandro Colomar <alx.manpages@gmail.com> | 2021-12-19 00:58:18 +0100 |
---|---|---|
committer | Alejandro Colomar <alx.manpages@gmail.com> | 2022-04-26 12:38:48 +0200 |
commit | a3d19f71a205d31ce141dcfd8880f7ed13bd65e5 (patch) | |
tree | da2cbedff9645553ec4b2ea20c1d509ef4f46d49 | |
parent | bce0f432c402ad18718aecab227b663160682ea4 (diff) | |
download | unit-a3d19f71a205d31ce141dcfd8880f7ed13bd65e5.tar.gz unit-a3d19f71a205d31ce141dcfd8880f7ed13bd65e5.tar.bz2 |
Fixed indentation.
Some lines (incorrectly) had an indentation of 3 or 5, or 7 or 9,
or 11 or 13, or 15 or 17 spaces instead of 4, 8, 12, or 16. Fix them.
Found with:
$ find src -type f | xargs grep -n '^ [^ ]';
$ find src -type f | xargs grep -n '^ [^ *]';
$ find src -type f | xargs grep -n '^ [^ ]';
$ find src -type f | xargs grep -n '^ [^ *]';
$ find src -type f | xargs grep -n '^ [^ +]';
$ find src -type f | xargs grep -n '^ [^ *+]';
$ find src -type f | xargs grep -n '^ [^ +]';
$ find src -type f | xargs grep -n '^ [^ *+]';
-rw-r--r-- | src/java/nginx/unit/websocket/WsRemoteEndpointImplBase.java | 2 | ||||
-rw-r--r-- | src/nxt_clone.c | 2 | ||||
-rw-r--r-- | src/nxt_conf_validation.c | 6 | ||||
-rw-r--r-- | src/nxt_gnutls.c | 4 | ||||
-rw-r--r-- | src/nxt_h1proto.c | 10 | ||||
-rw-r--r-- | src/nxt_http.h | 14 | ||||
-rw-r--r-- | src/nxt_http_route.c | 4 | ||||
-rw-r--r-- | src/nxt_main_process.c | 2 | ||||
-rw-r--r-- | src/nxt_mp.c | 16 | ||||
-rw-r--r-- | src/nxt_time_parse.c | 6 | ||||
-rw-r--r-- | src/nxt_unit.c | 4 | ||||
-rw-r--r-- | src/nxt_work_queue.h | 4 | ||||
-rw-r--r-- | src/perl/nxt_perl_psgi.c | 2 |
13 files changed, 38 insertions, 38 deletions
diff --git a/src/java/nginx/unit/websocket/WsRemoteEndpointImplBase.java b/src/java/nginx/unit/websocket/WsRemoteEndpointImplBase.java index 776124fd..d451db7d 100644 --- a/src/java/nginx/unit/websocket/WsRemoteEndpointImplBase.java +++ b/src/java/nginx/unit/websocket/WsRemoteEndpointImplBase.java @@ -1175,7 +1175,7 @@ public abstract class WsRemoteEndpointImplBase implements RemoteEndpoint { } else if (state == State.WRITER_WRITING) { // NO-OP. Leave state as is. } else if (state == State.STREAM_WRITING) { - // NO-OP. Leave state as is. + // NO-OP. Leave state as is. } else { // Should never happen // The if ... else ... blocks above should cover all states diff --git a/src/nxt_clone.c b/src/nxt_clone.c index 9ee3c012..aa952a54 100644 --- a/src/nxt_clone.c +++ b/src/nxt_clone.c @@ -384,7 +384,7 @@ nxt_clone_vldt_credential_gidmap(nxt_task_t *task, } return NXT_OK; - } + } base_ok = 0; gids_ok = 0; diff --git a/src/nxt_conf_validation.c b/src/nxt_conf_validation.c index 3f068bbb..4dd46dd8 100644 --- a/src/nxt_conf_validation.c +++ b/src/nxt_conf_validation.c @@ -114,7 +114,7 @@ static nxt_int_t nxt_conf_vldt_pass(nxt_conf_validation_t *vldt, static nxt_int_t nxt_conf_vldt_return(nxt_conf_validation_t *vldt, nxt_conf_value_t *value, void *data); static nxt_int_t nxt_conf_vldt_share(nxt_conf_validation_t *vldt, - nxt_conf_value_t *value, void *data); + nxt_conf_value_t *value, void *data); static nxt_int_t nxt_conf_vldt_share_element(nxt_conf_validation_t *vldt, nxt_conf_value_t *value); static nxt_int_t nxt_conf_vldt_proxy(nxt_conf_validation_t *vldt, @@ -194,7 +194,7 @@ static nxt_int_t nxt_conf_vldt_java_classpath(nxt_conf_validation_t *vldt, static nxt_int_t nxt_conf_vldt_java_option(nxt_conf_validation_t *vldt, nxt_conf_value_t *value); static nxt_int_t nxt_conf_vldt_upstream(nxt_conf_validation_t *vldt, - nxt_str_t *name, nxt_conf_value_t *value); + nxt_str_t *name, nxt_conf_value_t *value); static nxt_int_t nxt_conf_vldt_server(nxt_conf_validation_t *vldt, nxt_str_t *name, nxt_conf_value_t *value); static nxt_int_t nxt_conf_vldt_server_weight(nxt_conf_validation_t *vldt, @@ -2448,7 +2448,7 @@ nxt_conf_vldt_object(nxt_conf_validation_t *vldt, nxt_conf_value_t *value, break; } - } + } ret = nxt_conf_vldt_type(vldt, &name, member, vals->type); if (ret != NXT_OK) { diff --git a/src/nxt_gnutls.c b/src/nxt_gnutls.c index 4618dce9..aab4699c 100644 --- a/src/nxt_gnutls.c +++ b/src/nxt_gnutls.c @@ -708,11 +708,11 @@ nxt_gnutls_log_error_level(nxt_event_conn_t *c, ssize_t err) case GNUTLS_E_UNKNOWN_CIPHER_SUITE: /* -21 */ - /* Disable gnutls_bye(), because it returns GNUTLS_E_INTERNAL_ERROR. */ + /* Disable gnutls_bye(), because it returns GNUTLS_E_INTERNAL_ERROR. */ ssltls = c->u.ssltls; ssltls->no_shutdown = 1; - /* Fall through. */ + /* Fall through. */ case GNUTLS_E_UNEXPECTED_PACKET_LENGTH: /* -9 */ c->socket.error = 1000; /* Nonexistent errno code. */ diff --git a/src/nxt_h1proto.c b/src/nxt_h1proto.c index b683cb22..d3340774 100644 --- a/src/nxt_h1proto.c +++ b/src/nxt_h1proto.c @@ -1881,11 +1881,11 @@ nxt_h1p_idle_timeout(nxt_task_t *task, void *obj, void *data) #define NXT_H1P_IDLE_TIMEOUT \ - "HTTP/1.1 408 Request Timeout\r\n" \ - "Server: " NXT_SERVER "\r\n" \ - "Connection: close\r\n" \ - "Content-Length: 0\r\n" \ - "Date: " + "HTTP/1.1 408 Request Timeout\r\n" \ + "Server: " NXT_SERVER "\r\n" \ + "Connection: close\r\n" \ + "Content-Length: 0\r\n" \ + "Date: " static void diff --git a/src/nxt_http.h b/src/nxt_http.h index 02d66f58..7cef1345 100644 --- a/src/nxt_http.h +++ b/src/nxt_http.h @@ -90,17 +90,17 @@ typedef union { #define nxt_http_field_name_set(_field, _name) \ do { \ - (_field)->name_length = nxt_length(_name); \ - (_field)->name = (u_char *) _name; \ + (_field)->name_length = nxt_length(_name); \ + (_field)->name = (u_char *) _name; \ } while (0) #define nxt_http_field_set(_field, _name, _value) \ do { \ - (_field)->name_length = nxt_length(_name); \ - (_field)->value_length = nxt_length(_value); \ - (_field)->name = (u_char *) _name; \ - (_field)->value = (u_char *) _value; \ + (_field)->name_length = nxt_length(_name); \ + (_field)->value_length = nxt_length(_value); \ + (_field)->name = (u_char *) _name; \ + (_field)->value = (u_char *) _value; \ } while (0) @@ -238,7 +238,7 @@ typedef struct { void (*body_read)(nxt_task_t *task, nxt_http_request_t *r); void (*local_addr)(nxt_task_t *task, nxt_http_request_t *r); void (*header_send)(nxt_task_t *task, nxt_http_request_t *r, - nxt_work_handler_t body_handler, void *data); + nxt_work_handler_t body_handler, void *data); void (*send)(nxt_task_t *task, nxt_http_request_t *r, nxt_buf_t *out); nxt_off_t (*body_bytes_sent)(nxt_task_t *task, nxt_http_proto_t proto); void (*discard)(nxt_task_t *task, nxt_http_request_t *r, nxt_buf_t *last); diff --git a/src/nxt_http_route.c b/src/nxt_http_route.c index 9add051b..c2321906 100644 --- a/src/nxt_http_route.c +++ b/src/nxt_http_route.c @@ -932,7 +932,7 @@ nxt_http_route_rule_create(nxt_task_t *task, nxt_mp_t *mp, nxt_http_route_addr_rule_t * nxt_http_route_addr_rule_create(nxt_task_t *task, nxt_mp_t *mp, - nxt_conf_value_t *cv) + nxt_conf_value_t *cv) { size_t size; uint32_t i, n; @@ -2294,7 +2294,7 @@ nxt_http_route_cookie_parse(nxt_array_t *cookies, u_char *start, u_char *end) name = NULL; start = p + 1; - } + } } if (name != NULL) { diff --git a/src/nxt_main_process.c b/src/nxt_main_process.c index 9883f04c..03761a10 100644 --- a/src/nxt_main_process.c +++ b/src/nxt_main_process.c @@ -579,7 +579,7 @@ nxt_main_process_created_handler(nxt_task_t *task, nxt_port_recv_msg_t *msg) -1, msg->port_msg.stream, 0, NULL); return; } - } + } #endif diff --git a/src/nxt_mp.c b/src/nxt_mp.c index 4eaa16d0..d0de2c0e 100644 --- a/src/nxt_mp.c +++ b/src/nxt_mp.c @@ -939,12 +939,12 @@ nxt_mp_chunk_free(nxt_mp_t *mp, nxt_mp_block_t *cluster, u_char *p) page = cluster->pages; do { - if (page->size != 0) { - return NULL; - } + if (page->size != 0) { + return NULL; + } - page++; - n--; + page++; + n--; } while (n != 0); /* Free cluster. */ @@ -953,9 +953,9 @@ nxt_mp_chunk_free(nxt_mp_t *mp, nxt_mp_block_t *cluster, u_char *p) page = cluster->pages; do { - nxt_queue_remove(&page->link); - page++; - n--; + nxt_queue_remove(&page->link); + page++; + n--; } while (n != 0); nxt_rbtree_delete(&mp->blocks, &cluster->node); diff --git a/src/nxt_time_parse.c b/src/nxt_time_parse.c index 5a32b213..94c43289 100644 --- a/src/nxt_time_parse.c +++ b/src/nxt_time_parse.c @@ -282,9 +282,9 @@ nxt_time_parse(const u_char *p, size_t len) days = days - 719527 + 31 + 28; s = (uint64_t) days * 86400 - + (nxt_uint_t) hour * 3600 - + (nxt_uint_t) min * 60 - + (nxt_uint_t) sec; + + (nxt_uint_t) hour * 3600 + + (nxt_uint_t) min * 60 + + (nxt_uint_t) sec; #if (NXT_TIME_T_SIZE <= 4) diff --git a/src/nxt_unit.c b/src/nxt_unit.c index dac612b8..32bb07ab 100644 --- a/src/nxt_unit.c +++ b/src/nxt_unit.c @@ -5114,9 +5114,9 @@ nxt_unit_ctx_alloc(nxt_unit_ctx_t *ctx, void *data) rc = nxt_unit_ctx_init(lib, new_ctx, data); if (nxt_slow_path(rc != NXT_UNIT_OK)) { - nxt_unit_free(ctx, new_ctx); + nxt_unit_free(ctx, new_ctx); - return NULL; + return NULL; } queue_fd = -1; diff --git a/src/nxt_work_queue.h b/src/nxt_work_queue.h index 6c2d6c23..ffa21d27 100644 --- a/src/nxt_work_queue.h +++ b/src/nxt_work_queue.h @@ -16,12 +16,12 @@ struct nxt_task_s { uint32_t ident; nxt_work_t *next_work; - /* TODO: exception_handler, prev/next task, subtasks. */ + /* TODO: exception_handler, prev/next task, subtasks. */ }; #define nxt_task_next_ident() \ - ((uint32_t) nxt_atomic_fetch_add(&nxt_task_ident, 1) & 0x3FFFFFFF) + ((uint32_t) nxt_atomic_fetch_add(&nxt_task_ident, 1) & 0x3FFFFFFF) /* diff --git a/src/perl/nxt_perl_psgi.c b/src/perl/nxt_perl_psgi.c index 749ebd80..08a6f29e 100644 --- a/src/perl/nxt_perl_psgi.c +++ b/src/perl/nxt_perl_psgi.c @@ -612,7 +612,7 @@ nxt_perl_psgi_env_create(PerlInterpreter *my_perl, do { \ if (nxt_slow_path((FNS) != NXT_UNIT_OK)) \ goto fail; \ - } while (0) + } while (0) #define NL(S) (S), sizeof(S)-1 |