From 92fb46fb505d1e094811038d0abbe33805d52f33 Mon Sep 17 00:00:00 2001 From: "Carsten Haitzler (Rasterman)" Date: Mon, 24 Jul 2017 13:09:26 +0900 Subject: [PATCH] edje convert - make realloc fatal and complain about it cleaner error handling --- src/bin/edje/edje_convert.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/bin/edje/edje_convert.c b/src/bin/edje/edje_convert.c index 1a304a1..eb113a7f 100644 --- a/src/bin/edje/edje_convert.c +++ b/src/bin/edje/edje_convert.c @@ -192,7 +192,11 @@ _edje_collection_program_add(Edje_Program ***array, Edje_Program **tmp; tmp = realloc(*array, sizeof (Edje_Program*) * (*count + 1)); - if (!tmp) return; + if (!tmp) + { + error_and_abort(ef, "Not enough memory"); + return; + } tmp[(*count)++] = add; *array = tmp; -- 2.7.4