aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/core/json
diff options
context:
space:
mode:
authorGravatar David Klempner <klempner@imsanet.org>2015-02-04 14:40:42 -0800
committerGravatar David Klempner <klempner@imsanet.org>2015-02-04 14:40:42 -0800
commit05fce429e2a6503a839ac2a7f6854dafc6d188e9 (patch)
tree03754df5ae0b4a5b98f75c0ef097419bd8ea243e /test/core/json
parent034152f5befdc06dbd9b4bf613b8ab152c2625df (diff)
Fix a memory leak and a gpr_strdup/free mismatch in json_test
Diffstat (limited to 'test/core/json')
-rw-r--r--test/core/json/json_test.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/core/json/json_test.c b/test/core/json/json_test.c
index 11659a5716..6d0227ad39 100644
--- a/test/core/json/json_test.c
+++ b/test/core/json/json_test.c
@@ -151,7 +151,7 @@ static void test_pairs() {
GPR_ASSERT(!json);
}
- free(scratchpad);
+ gpr_free(scratchpad);
}
}
@@ -166,6 +166,7 @@ static void test_atypical() {
grpc_json_destroy(json->child);
json->child = brother;
grpc_json_destroy(json);
+ gpr_free(scratchpad);
}
int main(int argc, char **argv) {