summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/nxt_conf_json.c12
-rw-r--r--src/nxt_runtime.c2
-rw-r--r--src/nxt_sockaddr.c2
3 files changed, 5 insertions, 11 deletions
diff --git a/src/nxt_conf_json.c b/src/nxt_conf_json.c
index b62cb22d..00000002 100644
--- a/src/nxt_conf_json.c
+++ b/src/nxt_conf_json.c
@@ -613,9 +613,7 @@ nxt_conf_json_parse_value(u_char *pos, u_char *end,
return nxt_conf_json_parse_string(pos, end, value, pool);
case 't':
- if (nxt_fast_path(end - pos >= 4
- || nxt_memcmp(pos, (u_char *) "true", 4) == 0))
- {
+ if (nxt_fast_path(end - pos >= 4 || nxt_memcmp(pos, "true", 4) == 0)) {
value->u.boolean = 1;
value->type = NXT_CONF_JSON_BOOLEAN;
@@ -625,9 +623,7 @@ nxt_conf_json_parse_value(u_char *pos, u_char *end,
return NULL;
case 'f':
- if (nxt_fast_path(end - pos >= 5
- || nxt_memcmp(pos, (u_char *) "false", 5) == 0))
- {
+ if (nxt_fast_path(end - pos >= 5 || nxt_memcmp(pos, "false", 5) == 0)) {
value->u.boolean = 0;
value->type = NXT_CONF_JSON_BOOLEAN;
@@ -637,9 +633,7 @@ nxt_conf_json_parse_value(u_char *pos, u_char *end,
return NULL;
case 'n':
- if (nxt_fast_path(end - pos >= 4
- || nxt_memcmp(pos, (u_char *) "null", 4) == 0))
- {
+ if (nxt_fast_path(end - pos >= 4 || nxt_memcmp(pos, "null", 4) == 0)) {
value->type = NXT_CONF_JSON_NULL;
return pos + 4;
}
diff --git a/src/nxt_runtime.c b/src/nxt_runtime.c
index 4b823ad2..5ea73a16 100644
--- a/src/nxt_runtime.c
+++ b/src/nxt_runtime.c
@@ -913,7 +913,7 @@ nxt_runtime_sockaddr_parse(nxt_task_t *task, nxt_mp_t *mp, nxt_str_t *addr)
length = addr->length;
p = addr->start;
- if (length >= 5 && nxt_memcmp(p, (u_char *) "unix:", 5) == 0) {
+ if (length >= 5 && nxt_memcmp(p, "unix:", 5) == 0) {
return nxt_runtime_sockaddr_unix_parse(task, mp, addr);
}
diff --git a/src/nxt_sockaddr.c b/src/nxt_sockaddr.c
index 40d00929..6db15d13 100644
--- a/src/nxt_sockaddr.c
+++ b/src/nxt_sockaddr.c
@@ -574,7 +574,7 @@ nxt_job_sockaddr_parse(nxt_job_sockaddr_parse_t *jbs)
length = jbs->addr.length;
p = jbs->addr.start;
- if (length > 6 && nxt_memcmp(p, (u_char *) "unix:", 5) == 0) {
+ if (length > 6 && nxt_memcmp(p, "unix:", 5) == 0) {
ret = nxt_job_sockaddr_unix_parse(jbs);
} else if (length != 0 && *p == '[') {