diff --git a/fcgi.c b/fcgi.c index 5e2ba57..6fbb21b 100644 --- a/fcgi.c +++ b/fcgi.c @@ -135,7 +135,7 @@ prepare_header(struct fcgi_header *h, int type, size_t size, memset(h, 0, sizeof(*h)); h->version = FCGI_VERSION_1; - h->type = type; + h->type = type; h->req_id1 = (id >> 8); h->req_id0 = (id & 0xFF); h->content_len1 = (size >> 8); @@ -168,7 +168,7 @@ fcgi_send_param(struct bufferevent *bev, const char *name, const char *value) { struct fcgi_header h; - uint32_t namlen, vallen, padlen; + uint32_t namlen, vallen, padlen; uint8_t s[8]; size_t size; char padding[8] = { 0 }; diff --git a/iri.c b/iri.c index fd34c2e..ae292d0 100644 --- a/iri.c +++ b/iri.c @@ -229,7 +229,7 @@ path_elide_dotdot(char *path, char *i, int incr) if (i == path) return 0; for (j = i-2; j != path && *j != '/'; j--) - /* noop */ ; + /* noop */ ; if (*j == '/') j++; i += incr; @@ -428,7 +428,7 @@ serialize_iri(struct iri *i, char *buf, size_t len) strlcpy(buf, i->schema, len); strlcat(buf, "://", len); - strlcat(buf, i->host, len); + strlcat(buf, i->host, len); strlcat(buf, "/", len); if (i->path != NULL) diff --git a/sandbox.c b/sandbox.c index 5391f03..8857c4b 100644 --- a/sandbox.c +++ b/sandbox.c @@ -29,7 +29,7 @@ sandbox_server_process(void) void sandbox_executor_process(void) { - log_notice(NULL, "Sandbox disabled! " + log_notice(NULL, "Sandbox disabled! " "Please report issues upstream instead of disabling the sandbox."); } @@ -322,7 +322,7 @@ static struct sock_filter filter[] = { #endif #ifdef __NR_ioctl /* allow ioctl on fd 1, glibc doing stuff? */ - SC_ALLOW_ARG(__NR_ioctl, 0, 1), + SC_ALLOW_ARG(__NR_ioctl, 0, 1), /* allow FIONREAD needed by libevent */ SC_ALLOW_ARG(__NR_ioctl, 1, FIONREAD), #endif @@ -645,7 +645,7 @@ sandbox_executor_process(void) } for (i = 0; i < FCGI_MAX; i++) { - f = &fcgi[i]; + f = &fcgi[i]; if (f->path != NULL) { if (unveil(f->path, "rw") == -1) fatal("unveil %s", f->path); diff --git a/server.c b/server.c index 9bd17a3..88fcc70 100644 --- a/server.c +++ b/server.c @@ -540,7 +540,7 @@ static void fmt_sbuf(const char *fmt, struct client *c, const char *path) { size_t i; - char buf[32]; + char buf[32]; memset(buf, 0, sizeof(buf)); for (i = 0; *fmt; ++fmt) { @@ -794,7 +794,7 @@ open_dir(struct client *c) c->diroff = 0; c->off = 0; - start_reply(c, SUCCESS, "text/gemini"); + start_reply(c, SUCCESS, "text/gemini"); evbuffer_add_printf(EVBUFFER_OUTPUT(c->bev), "# Index of %s\n\n", c->iri.path); return; @@ -1093,7 +1093,7 @@ start_reply(struct client *c, int code, const char *meta) c->type != REQUEST_FCGI && !strcmp(meta, "text/gemini") && (lang = vhost_lang(c->host, c->iri.path)) != NULL) { - rr = evbuffer_add_printf(evb, ";lang=%s", lang); + rr = evbuffer_add_printf(evb, ";lang=%s", lang); if (rr == -1) goto err; if (r + rr > 1027) diff --git a/utf8.c b/utf8.c index acba5eb..72545b2 100644 --- a/utf8.c +++ b/utf8.c @@ -65,7 +65,7 @@ valid_multibyte_utf8(struct parser *p) { uint32_t cp = 0, state = 0; - for (; *p->iri; p->iri++) + for (; *p->iri; p->iri++) if (!utf8_decode(&state, &cp, *p->iri)) break; diff --git a/utils.c b/utils.c index 9a67ff6..1a9a0e0 100644 --- a/utils.c +++ b/utils.c @@ -122,7 +122,7 @@ gen_certificate(const char *hostname, const char *certpath, const char *keypath) host); if ((pkey = EVP_PKEY_new()) == NULL) - fatal("couldn't create a new private key"); + fatal("couldn't create a new private key"); if ((rsa = RSA_new()) == NULL) fatal("couldn't generate rsa"); @@ -154,7 +154,7 @@ gen_certificate(const char *hostname, const char *certpath, const char *keypath) X509_set_issuer_name(x509, name); if (!X509_sign(x509, pkey, EVP_sha256())) - fatal("couldn't sign the certificate"); + fatal("couldn't sign the certificate"); if ((f = fopen(keypath, "w")) == NULL) fatal("fopen(%s): %s", keypath, strerror(errno));