nghttpx: Fix bug that zero-length POST is not forwarded

This commit is contained in:
Tatsuhiro Tsujikawa 2016-11-11 00:48:32 +09:00
parent f4474d57ec
commit 2b75aff32e
1 changed files with 2 additions and 2 deletions

View File

@ -561,6 +561,8 @@ int HttpDownstreamConnection::push_upload_data_chunk(const uint8_t *data,
} }
int HttpDownstreamConnection::end_upload_data() { int HttpDownstreamConnection::end_upload_data() {
signal_write();
if (!downstream_->get_chunked_request()) { if (!downstream_->get_chunked_request()) {
return 0; return 0;
} }
@ -577,8 +579,6 @@ int HttpDownstreamConnection::end_upload_data() {
output->append("\r\n"); output->append("\r\n");
} }
signal_write();
return 0; return 0;
} }