Fix http parser

This commit is contained in:
ruti 2024-03-01 01:27:04 +03:00
parent 5f60a671a3
commit 82e5229df0

View File

@ -177,8 +177,11 @@ int parse_http(char *buffer, size_t bsize, char **hs, uint16_t *port)
h_end = 0;
do {
h = memchr(h, ':', l_end - h);
if (h) h_end = h;
} while (h);
if (h) {
h_end = h;
h++;
}
} while (h && h < l_end);
}
if (!h_end) {