From eb46816470b3a3c54fc979fe916f80cf43d38ac8 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Thu, 2 Feb 2017 08:37:22 -0800 Subject: [PATCH] Fix potential use-after-free --- test/core/end2end/tests/resource_quota_server.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/core/end2end/tests/resource_quota_server.c b/test/core/end2end/tests/resource_quota_server.c index 4dd3204e45f..3aeb9b27f3c 100644 --- a/test/core/end2end/tests/resource_quota_server.c +++ b/test/core/end2end/tests/resource_quota_server.c @@ -362,6 +362,9 @@ void resource_quota_server(grpc_end2end_test_config config) { grpc_slice_unref(request_payload_slice); grpc_resource_quota_unref(resource_quota); + end_test(&f); + config.tear_down_data(&f); + free(client_calls); free(server_calls); free(initial_metadata_recv); @@ -372,9 +375,6 @@ void resource_quota_server(grpc_end2end_test_config config) { free(details); free(request_payload_recv); free(was_cancelled); - - end_test(&f); - config.tear_down_data(&f); } void resource_quota_server_pre_init(void) {}