From 4f5e4e07653da82b28fc4141ae253481e0426a63 Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Fri, 14 Jan 2011 06:35:41 +0000 Subject: [PATCH] sighhh add more calloc checks SVN revision: 56100 --- legacy/evas/src/lib/engines/common/evas_font_draw.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/legacy/evas/src/lib/engines/common/evas_font_draw.c b/legacy/evas/src/lib/engines/common/evas_font_draw.c index 6adcb18e24..6067f927c9 100644 --- a/legacy/evas/src/lib/engines/common/evas_font_draw.c +++ b/legacy/evas/src/lib/engines/common/evas_font_draw.c @@ -125,8 +125,10 @@ _fash_int_add(Fash_Int *fash, int item, RGBA_Font_Int *fint, int index) min = item & 0xff; if (!fash->bucket[grp]) fash->bucket[grp] = calloc(1, sizeof(Fash_Int_Map2)); + EINA_SAFETY_ON_NULL_RETURN(fash->bucket[grp]); if (!fash->bucket[grp]->bucket[maj]) fash->bucket[grp]->bucket[maj] = calloc(1, sizeof(Fash_Int_Map)); + EINA_SAFETY_ON_NULL_RETURN(fash->bucket[grp]->bucket[maj]); fash->bucket[grp]->bucket[maj]->item[min].fint = fint; fash->bucket[grp]->bucket[maj]->item[min].index = index; } @@ -182,6 +184,7 @@ _fash_gl_add(Fash_Glyph *fash, int item, RGBA_Font_Glyph *glyph) min = item & 0xff; if (!fash->bucket[grp]) fash->bucket[grp] = calloc(1, sizeof(Fash_Glyph_Map2)); + EINA_SAFETY_ON_NULL_RETURN(fash->bucket[grp]); if (!fash->bucket[grp]->bucket[maj]) fash->bucket[grp]->bucket[maj] = calloc(1, sizeof(Fash_Glyph_Map)); EINA_SAFETY_ON_NULL_RETURN(fash->bucket[grp]->bucket[maj]);