mirror of
https://github.com/cuberite/libevent.git
synced 2025-09-11 13:24:43 -04:00
Merge pull request #190 from JohnOhl/evhttp-post-fix
evhttp: Fix failure to send all output data for POST/PUT requests
This commit is contained in:
commit
bdeec440f1
3
http.c
3
http.c
@ -1125,6 +1125,9 @@ evhttp_write_connectioncb(struct evhttp_connection *evcon, void *arg)
|
||||
|
||||
EVUTIL_ASSERT(evcon->state == EVCON_WRITING);
|
||||
|
||||
/* We need to wait until we've written all of our output data before we can continue */
|
||||
if (evbuffer_get_length(bufferevent_get_output(evcon->bufev)) > 0) { return; }
|
||||
|
||||
/* We are done writing our header and are now expecting the response */
|
||||
req->kind = EVHTTP_RESPONSE;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user