nghttpx: Fix bug: end marker of chunked encoding is written twice

This commit is contained in:
Tatsuhiro Tsujikawa 2013-07-30 21:46:00 +09:00
parent 8ca501ae57
commit ab56cd4ea3
1 changed files with 3 additions and 0 deletions

View File

@ -702,6 +702,9 @@ int HttpsUpstream::on_downstream_body(Downstream *downstream,
const uint8_t *data, size_t len) const uint8_t *data, size_t len)
{ {
int rv; int rv;
if(len == 0) {
return 0;
}
evbuffer *output = bufferevent_get_output(handler_->get_bev()); evbuffer *output = bufferevent_get_output(handler_->get_bev());
if(downstream->get_chunked_response()) { if(downstream->get_chunked_response()) {
char chunk_size_hex[16]; char chunk_size_hex[16];