diff options
Diffstat (limited to 'libglusterfs')
-rw-r--r-- | libglusterfs/src/mem-types.h | 1 | ||||
-rw-r--r-- | libglusterfs/src/parse-utils.c | 8 |
2 files changed, 5 insertions, 4 deletions
diff --git a/libglusterfs/src/mem-types.h b/libglusterfs/src/mem-types.h index 0db06f52c98..93aea8502e3 100644 --- a/libglusterfs/src/mem-types.h +++ b/libglusterfs/src/mem-types.h @@ -128,6 +128,7 @@ enum gf_common_mem_types_ { gf_common_mt_ereg = 112, gf_common_mt_wr = 113, gf_common_mt_rdma_arena_mr = 114, + gf_common_mt_parser_t = 115, gf_common_mt_end }; #endif diff --git a/libglusterfs/src/parse-utils.c b/libglusterfs/src/parse-utils.c index 3934586aa32..f7e9988ab64 100644 --- a/libglusterfs/src/parse-utils.c +++ b/libglusterfs/src/parse-utils.c @@ -40,7 +40,7 @@ parser_init (const char *regex) int rc = 0; struct parser *parser = NULL; - parser = MALLOC (sizeof(*parser)); + parser = GF_MALLOC (sizeof(*parser), gf_common_mt_parser_t); if (!parser) goto out; @@ -48,7 +48,7 @@ parser_init (const char *regex) if (!parser->regex) { gf_log (GF_PARSE, GF_LOG_INFO, "Failed to duplicate regex string!"); - FREE (parser); + GF_FREE (parser); parser = NULL; goto out; } @@ -135,9 +135,9 @@ parser_deinit (struct parser *ptr) return; regfree (&ptr->preg); - FREE (ptr->complete_str); + GF_FREE (ptr->complete_str); GF_FREE (ptr->regex); - FREE (ptr); + GF_FREE (ptr); } /** |