From d4ade2d7d0a10d554800485c6a7cc2e800a3b81d Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Sat, 3 Aug 2013 23:45:28 +0900 Subject: [PATCH] nghttpx: Return -1 if dconn_ is nullptr on push_upload_data_chunk --- src/shrpx_downstream.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shrpx_downstream.cc b/src/shrpx_downstream.cc index 64c3c729..fccb3c05 100644 --- a/src/shrpx_downstream.cc +++ b/src/shrpx_downstream.cc @@ -318,7 +318,7 @@ int Downstream::push_upload_data_chunk(const uint8_t *data, size_t datalen) // buffer using push_request_headers(). if(!dconn_) { DLOG(WARNING, this) << "dconn_ is NULL"; - return 0; + return -1; } request_bodylen_ += datalen; return dconn_->push_upload_data_chunk(data, datalen);