summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authorHermet Park <hermetpark@gmail.com>2019-11-21 17:28:54 +0900
committerHermet Park <hermetpark@gmail.com>2019-11-21 17:28:54 +0900
commitce30a952b2521632c4cde8bbb5c33313c62e47ae (patch)
tree8d1a5a1b4e1ee4b9b8abea3b7f6341d3540d26c0 /src/modules
parent959c503a718ed548fa3251fc245bfe9c8c82d521 (diff)
vector json: checking valid pointer before accessing it.
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/evas/vg_loaders/json/evas_vg_load_json.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/modules/evas/vg_loaders/json/evas_vg_load_json.c b/src/modules/evas/vg_loaders/json/evas_vg_load_json.c
index 60a0d06916..ba60b444f1 100644
--- a/src/modules/evas/vg_loaders/json/evas_vg_load_json.c
+++ b/src/modules/evas/vg_loaders/json/evas_vg_load_json.c
@@ -20,14 +20,17 @@ evas_vg_load_file_close_json(Vg_File_Data *vfd)
20 20
21 Lottie_Animation *lot_anim = (Lottie_Animation *) vfd->loader_data; 21 Lottie_Animation *lot_anim = (Lottie_Animation *) vfd->loader_data;
22 lottie_animation_destroy(lot_anim); 22 lottie_animation_destroy(lot_anim);
23 if (vfd->anim_data->markers) 23 if (vfd->anim_data)
24 { 24 {
25 Vg_File_Anim_Data_Marker *marker; 25 if (vfd->anim_data->markers)
26 EINA_INARRAY_FOREACH(vfd->anim_data->markers, marker) 26 {
27 if (marker->name) eina_stringshare_del(marker->name); 27 Vg_File_Anim_Data_Marker *marker;
28 eina_inarray_free(vfd->anim_data->markers); 28 EINA_INARRAY_FOREACH(vfd->anim_data->markers, marker)
29 if (marker->name) eina_stringshare_del(marker->name);
30 eina_inarray_free(vfd->anim_data->markers);
31 }
32 free(vfd->anim_data);
29 } 33 }
30 if (vfd->anim_data) free(vfd->anim_data);
31 if (vfd->root) efl_unref(vfd->root); 34 if (vfd->root) efl_unref(vfd->root);
32 free(vfd); 35 free(vfd);
33 36