diff options
author | 2015-05-08 08:33:23 -0700 | |
---|---|---|
committer | 2015-05-08 08:33:23 -0700 | |
commit | 72a96463f689748c7b63c9f39f92d33e87e87315 (patch) | |
tree | 34bf6d8097012a5b60ace23029bf9c8feffa8716 | |
parent | bc2c63cda61c048332d8263fa658450cd8fcad37 (diff) | |
parent | c5f3e268a1c6aa3721a951c127d84d408935a047 (diff) |
Merge pull request #1511 from ctiller/i-forgot-stuff
Fix potential leak
-rw-r--r-- | src/core/surface/call.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core/surface/call.c b/src/core/surface/call.c index 9ee91785e8..f3658b56c4 100644 --- a/src/core/surface/call.c +++ b/src/core/surface/call.c @@ -711,6 +711,10 @@ static void call_on_done_recv(void *pc, int success) { break; } } + if (!success) { + grpc_stream_ops_unref_owned_objects(&call->recv_ops.ops[i], + call->recv_ops.nops - i); + } if (call->recv_state == GRPC_STREAM_RECV_CLOSED) { GPR_ASSERT(call->read_state <= READ_STATE_READ_CLOSED); call->read_state = READ_STATE_READ_CLOSED; |