aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/core/util/passthru_endpoint.c
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2017-05-05 17:52:01 +0000
committerGravatar Craig Tiller <ctiller@google.com>2017-05-05 17:52:01 +0000
commita37ad7d1345e48dff8a60b92af384b99086f6ae6 (patch)
treec4bc7feef08271ec06e95511c51d5f3fcc1674c8 /test/core/util/passthru_endpoint.c
parent9247817082bc5d33ebe048a1aa0c5881fdb408ed (diff)
parent0994bbd0f7d8e97ca946ee97f24643d79e5d2c3e (diff)
Merge branch 'trickle_stall' of github.com:ctiller/grpc into trickle_stall
Diffstat (limited to 'test/core/util/passthru_endpoint.c')
-rw-r--r--test/core/util/passthru_endpoint.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/core/util/passthru_endpoint.c b/test/core/util/passthru_endpoint.c
index 121567fc0d..6400845d23 100644
--- a/test/core/util/passthru_endpoint.c
+++ b/test/core/util/passthru_endpoint.c
@@ -102,13 +102,14 @@ static void me_write(grpc_exec_ctx *exec_ctx, grpc_endpoint *ep,
error = GRPC_ERROR_CREATE_FROM_STATIC_STRING("Endpoint already shutdown");
} else if (m->on_read != NULL) {
for (size_t i = 0; i < slices->count; i++) {
- grpc_slice_buffer_add(m->on_read_out, grpc_slice_ref(slices->slices[i]));
+ grpc_slice_buffer_add(m->on_read_out, grpc_slice_copy(slices->slices[i]));
}
grpc_closure_sched(exec_ctx, m->on_read, GRPC_ERROR_NONE);
m->on_read = NULL;
} else {
for (size_t i = 0; i < slices->count; i++) {
- grpc_slice_buffer_add(&m->read_buffer, grpc_slice_ref(slices->slices[i]));
+ grpc_slice_buffer_add(&m->read_buffer,
+ grpc_slice_copy(slices->slices[i]));
}
}
gpr_mu_unlock(&m->parent->mu);