diff options
author | Kovarththanan Rajaratnam <kovarththanan.rajaratnam@gmail.com> | 2009-10-05 18:20:38 +0000 |
---|---|---|
committer | Kovarththanan Rajaratnam <kovarththanan.rajaratnam@gmail.com> | 2009-10-05 18:20:38 +0000 |
commit | e567d96a93baf737a1ec89c3b3ee2c2f38b4f758 (patch) | |
tree | a71580430e0edc9c1eb3041c4a64ee0e782cbd47 /epan/emem.c | |
parent | 50be430dab0fda1cdf707e04ba580af02df7b1f6 (diff) |
Use g_malloc()
svn path=/trunk/; revision=30342
Diffstat (limited to 'epan/emem.c')
-rw-r--r-- | epan/emem.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/epan/emem.c b/epan/emem.c index c40ddf2c1f..8688378d66 100644 --- a/epan/emem.c +++ b/epan/emem.c @@ -394,7 +394,7 @@ emem_create_chunk(emem_chunk_t **free_list, gboolean use_canary) { npc->free_offset = npc->free_offset_init; #else /* Is there a draft in here? */ - npc->buf = malloc(EMEM_PACKET_CHUNK_SIZE); + npc->buf = g_malloc(EMEM_PACKET_CHUNK_SIZE); if(npc->buf == NULL) { THROW(OutOfMemoryError); } @@ -834,7 +834,7 @@ se_tree_create(int type, const char *name) { emem_tree_t *tree_list; - tree_list=malloc(sizeof(emem_tree_t)); + tree_list=g_malloc(sizeof(emem_tree_t)); tree_list->next=se_trees; tree_list->type=type; tree_list->tree=NULL; @@ -1417,7 +1417,7 @@ emem_tree_insert_string(emem_tree_t* se_tree, const gchar* k, void* v, guint32 f guint32 i; guint32 tmp; - aligned = malloc(div * sizeof (guint32)); + aligned = g_malloc(div * sizeof (guint32)); /* pack the bytes one one by one into guint32s */ tmp = 0; @@ -1470,7 +1470,7 @@ emem_tree_lookup_string(emem_tree_t* se_tree, const gchar* k, guint32 flags) guint32 tmp; void *ret; - aligned = malloc(div * sizeof (guint32)); + aligned = g_malloc(div * sizeof (guint32)); /* pack the bytes one one by one into guint32s */ tmp = 0; |