aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib/json
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2017-02-16 14:09:39 -0800
committerGravatar Craig Tiller <ctiller@google.com>2017-02-16 14:09:39 -0800
commit6f4178878ccc45f365ce72eef6247315e048cf2a (patch)
tree91e01ba6e683014839aa60e22069713e6229c2c7 /src/core/lib/json
parent1ca0dc2a9b22c144e2a5153394266037e497635e (diff)
Add zalloc, convert a bunch of files to use it
Diffstat (limited to 'src/core/lib/json')
-rw-r--r--src/core/lib/json/json.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/core/lib/json/json.c b/src/core/lib/json/json.c
index 48b13686d7..5f7e4ec042 100644
--- a/src/core/lib/json/json.c
+++ b/src/core/lib/json/json.c
@@ -38,8 +38,7 @@
#include "src/core/lib/json/json.h"
grpc_json* grpc_json_create(grpc_json_type type) {
- grpc_json* json = gpr_malloc(sizeof(*json));
- memset(json, 0, sizeof(*json));
+ grpc_json* json = gpr_zalloc(sizeof(*json));
json->type = type;
return json;