diff --git a/src/http/parser/parse.c b/src/http/parser/parse.c index 742ffd2..ad12b67 100644 --- a/src/http/parser/parse.c +++ b/src/http/parser/parse.c @@ -83,7 +83,7 @@ httpParserParse(void * _this, Stream st) case HTTP_MESSAGE_START: if (NULL == (line = cbufGetLine(this->buffer, &line_end))) { if (! cbufIsEmpty(this->buffer)) { - this->isize = this->buffer->bused; + this->isize = this->buffer->bused; this->incomplete = malloc(this->isize); memcpy(this->incomplete, cbufGetData(this->buffer, this->isize), diff --git a/src/server/server.c b/src/server/server.c index 5f43eb0..8f76a3a 100644 --- a/src/server/server.c +++ b/src/server/server.c @@ -61,15 +61,15 @@ serverCtor(void * _this, va_list * params) port = va_arg(* params, int); backlog = va_arg(* params, unsigned int); - this->fds = calloc(sizeof(struct pollfd), this->max_fds); - this->conns = calloc(sizeof(struct conns), this->max_fds); + this->fds = calloc(sizeof(struct pollfd), this->max_fds); + this->conns = calloc(sizeof(struct conns), this->max_fds); - this->sock = new(Sock, this->logger, port); - flags = fcntl(this->sock->handle, F_GETFL, 0); + this->sock = new(Sock, this->logger, port); + flags = fcntl(this->sock->handle, F_GETFL, 0); fcntl(this->sock->handle, F_SETFL, flags | O_NONBLOCK); this->sockSSL = new(Sock, this->logger, port+1); - flags = fcntl(this->sockSSL->handle, F_GETFL, 0); + flags = fcntl(this->sockSSL->handle, F_GETFL, 0); fcntl(this->sockSSL->handle, F_SETFL, flags | O_NONBLOCK); SSL_library_init();