summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunsuChoi <jsuya.choi@samsung.com>2016-09-20 23:34:17 +0900
committerJaehyun Cho <jae_hyun.cho@samsung.com>2016-09-21 09:42:46 +0900
commitbed6c84afb2694d3a1186c6878b9338503f55021 (patch)
treeb67b73129b1e75dbaf96e7f6a0040d23df528b0b
parent8f66497acac27ef9bf53026429fa221b7e2a3f27 (diff)
edje_edit : add null check and close eet
Signed-off-by: Jaehyun Cho <jae_hyun.cho@samsung.com>
-rw-r--r--src/lib/edje/edje_edit.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/lib/edje/edje_edit.c b/src/lib/edje/edje_edit.c
index f3381fa76c..65e490ced8 100644
--- a/src/lib/edje/edje_edit.c
+++ b/src/lib/edje/edje_edit.c
@@ -1675,6 +1675,11 @@ edje_edit_group_copy(Evas_Object *obj, const char *group_name, const char *copy_
1675 } 1675 }
1676 snprintf(buf, sizeof(buf), "edje/collections/%d", e->id); 1676 snprintf(buf, sizeof(buf), "edje/collections/%d", e->id);
1677 epc = eet_data_read(eetf, _edje_edd_edje_part_collection, buf); 1677 epc = eet_data_read(eetf, _edje_edd_edje_part_collection, buf);
1678 if (!epc)
1679 {
1680 eet_close(eetf);
1681 return EINA_FALSE;
1682 }
1678 1683
1679 /* Search first free id */ 1684 /* Search first free id */
1680 id = -1; 1685 id = -1;
@@ -1703,7 +1708,11 @@ edje_edit_group_copy(Evas_Object *obj, const char *group_name, const char *copy_
1703 1708
1704 /* Create structs */ 1709 /* Create structs */
1705 de = _alloc(sizeof(Edje_Part_Collection_Directory_Entry)); 1710 de = _alloc(sizeof(Edje_Part_Collection_Directory_Entry));
1706 if (!de) return EINA_FALSE; 1711 if (!de)
1712 {
1713 eet_close(eetf);
1714 return EINA_FALSE;
1715 }
1707 1716
1708 /* Init Edje_Part_Collection_Directory_Entry */ 1717 /* Init Edje_Part_Collection_Directory_Entry */
1709 de->id = id; 1718 de->id = id;