Skip to content

Commit

Permalink
wasm: fix network leak (envoyproxy#13836)
Browse files Browse the repository at this point in the history
Signed-off-by: Kuat Yessenov <[email protected]>

Signed-off-by: Kuat <[email protected]>
  • Loading branch information
kyessenov authored and bianpengyuan committed Jan 28, 2021
1 parent a0eff54 commit df6f749
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions source/extensions/common/wasm/context.cc
Original file line number Diff line number Diff line change
Expand Up @@ -724,11 +724,7 @@ BufferInterface* Context::getBuffer(WasmBufferType type) {
void Context::onDownstreamConnectionClose(CloseType close_type) {
ContextBase::onDownstreamConnectionClose(close_type);
downstream_closed_ = true;
// Call close on TCP connection, if upstream connection closed or there was a failure seen in this
// connection.
if (upstream_closed_ || getRequestStreamInfo()->hasAnyResponseFlag()) {
onCloseTCP();
}
onCloseTCP();
}

void Context::onUpstreamConnectionClose(CloseType close_type) {
Expand Down

0 comments on commit df6f749

Please sign in to comment.