mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-09-21 22:01:31 +02:00
MINOR: httpclient: Don't limit data transfer to 1024 bytes
For debug purpose, no more 1024 bytes were copied at a time. But there is no reason to keep this limitation. Thus, it is removed. This patch may be backported to 2.5.
This commit is contained in:
parent
6ced61dd0a
commit
fc5912914b
@ -7175,7 +7175,7 @@ __LJMP static int hlua_httpclient_snd_yield(lua_State *L, int status, lua_KConte
|
|||||||
body_str = lua_tolstring(L, -1, &buf_len);
|
body_str = lua_tolstring(L, -1, &buf_len);
|
||||||
lua_pop(L, 1);
|
lua_pop(L, 1);
|
||||||
|
|
||||||
to_send = MIN(buf_len - hlua_hc->sent, 1024);
|
to_send = buf_len - hlua_hc->sent;
|
||||||
|
|
||||||
if ((hlua_hc->sent + to_send) >= buf_len)
|
if ((hlua_hc->sent + to_send) >= buf_len)
|
||||||
end = 1;
|
end = 1;
|
||||||
|
@ -353,7 +353,7 @@ int httpclient_res_xfer(struct httpclient *hc, struct buffer *dst)
|
|||||||
{
|
{
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
ret = b_force_xfer(dst, &hc->res.buf, MIN(1024, b_data(&hc->res.buf)));
|
ret = b_force_xfer(dst, &hc->res.buf, b_data(&hc->res.buf));
|
||||||
/* call the client once we consumed all data */
|
/* call the client once we consumed all data */
|
||||||
if (!b_data(&hc->res.buf)) {
|
if (!b_data(&hc->res.buf)) {
|
||||||
b_free(&hc->res.buf);
|
b_free(&hc->res.buf);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user