Browse Source

fix headers size calculation

pull/2/head
Ivan Polyakov 2 years ago
parent
commit
56ca12fb63
  1. 2
      c/response.c

2
c/response.c

@ -97,7 +97,7 @@ static size_t calc_res_headers_sz(const rpd_keyval *headers)
while (i < headers->size) { while (i < headers->size) {
size += strlen(headers->items[i].key); size += strlen(headers->items[i].key);
size++; /* plus space */ size += 2; /* plus ": " */
size += strlen(headers->items[i].val); size += strlen(headers->items[i].val);
size += 2; /* plus CRLF */ size += 2; /* plus CRLF */
i++; i++;

Loading…
Cancel
Save