mirror of
https://github.com/jorisvink/kore
synced 2025-03-09 12:39:01 -04:00
make sure we advance the host buffer properly
This commit is contained in:
parent
f1fa108f98
commit
53cbc1a21e
@ -292,11 +292,13 @@ http_header_recv(struct netbuf *nb)
|
||||
return (KORE_RESULT_ERROR);
|
||||
}
|
||||
|
||||
if (strlen(host[0]) != 4 || strncasecmp(host[0], "host", 4)) {
|
||||
if (strlen(host[0]) != 4 || strncasecmp(host[0], "host", 4) ||
|
||||
strlen(host[1]) < 3) {
|
||||
free(hbuf);
|
||||
return (KORE_RESULT_ERROR);
|
||||
}
|
||||
|
||||
host[1]++;
|
||||
if (!http_request_new(c, NULL, host[1], request[0], request[1], &req)) {
|
||||
free(hbuf);
|
||||
return (KORE_RESULT_ERROR);
|
||||
|
Loading…
x
Reference in New Issue
Block a user