diff options
author | Felix Fietkau <nbd@openwrt.org> | 2013-01-19 16:48:05 +0100 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2013-01-19 16:48:05 +0100 |
commit | 9cfe019ff4b6637e2bb7fbf5fc8db37abdd3c569 (patch) | |
tree | f9a0859975add6b22685b3396d99a004077970af | |
parent | 70b9f135f8400349838df2d682a073a0706245c5 (diff) |
ignore initial newlines in http requests
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
-rw-r--r-- | client.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -193,6 +193,9 @@ static bool client_init_cb(struct client *cl, char *buf, int len) if (!newline) return false; + if (newline == buf) + return true; + *newline = 0; blob_buf_init(&cl->hdr, 0); cl->state = client_parse_request(cl, buf); |