Make redbean Fetch() support longer responses

Fixes #1315
This commit is contained in:
Justine Tunney 2024-10-12 15:59:46 -07:00
parent dc1afc968b
commit 4abcba8d8f
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
2 changed files with 20 additions and 1 deletions

View file

@ -378,7 +378,7 @@ static int LuaFetch(lua_State *L) {
WARNF("(ftch) HTTP client %s error", "EOF headers");
goto TransportError;
}
rc = ParseHttpMessage(&msg, inbuf.p, inbuf.n, inbuf.c);
rc = ParseHttpMessage(&msg, inbuf.p, inbuf.n, SHRT_MAX);
if (rc == -1) {
WARNF("(ftch) HTTP client %s error", "ParseHttpMessage");
goto TransportError;