summaryrefslogtreecommitdiff
path: root/src/lib/evas/include
diff options
context:
space:
mode:
authorPankaj Mittal <m.pankaj@samsung.com>2015-12-10 16:26:56 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2015-12-10 16:26:56 +0900
commit1363cd757a8dcdc9adeaf47f781ad038446b2014 (patch)
tree5cb4b8deb2c4627b57d170269f0fd2bbb244344c /src/lib/evas/include
parentd63cc52c584e0b3304699bd1822df18c0b446e2b (diff)
evas_eet: Add Type Safety check
Summary: The Function _evas_canvas3d_eet_file_free(void) is referenced in evas_model_load_file_eet()(file:evas_model_load_eet.c at line 122). This call is under condition if ((eet_file->mesh == NULL) || (eet_file->header == NULL)). when either eet_file->mesh or eet_file->header are NULL, dereference of the corresponding pointer in function "_evas_canvas3d_eet_file_free()" will generate Segmentation Fault. @fix Reviewers: raster, Hermet, tasn, wonsik, spacegrapher, cedric, jpeg Subscribers: singh.amitesh, sachin.dev, alok25, yashu21985, mvsovani, cedric Differential Revision: https://phab.enlightenment.org/D3369
Diffstat (limited to 'src/lib/evas/include')
-rw-r--r--src/lib/evas/include/evas_common_private.h3
-rw-r--r--src/lib/evas/include/evas_private.h8
2 files changed, 8 insertions, 3 deletions
diff --git a/src/lib/evas/include/evas_common_private.h b/src/lib/evas/include/evas_common_private.h
index f7deaa7f42..cf29f2d345 100644
--- a/src/lib/evas/include/evas_common_private.h
+++ b/src/lib/evas/include/evas_common_private.h
@@ -90,6 +90,9 @@
90#define lround(x) (((x) < 0) ? (long int)ceil((x) - 0.5) : (long int)floor((x) + 0.5)) 90#define lround(x) (((x) < 0) ? (long int)ceil((x) - 0.5) : (long int)floor((x) + 0.5))
91#endif 91#endif
92 92
93/*macro to be used in eet loader/saver*/
94#define EVAS_CANVAS3D_FILE_CACHE_FILE_ENTRY "evas_3d file"
95
93/* macros needed to log message through eina_log */ 96/* macros needed to log message through eina_log */
94extern EAPI int _evas_log_dom_global; 97extern EAPI int _evas_log_dom_global;
95#ifdef _EVAS_DEFAULT_LOG_DOM 98#ifdef _EVAS_DEFAULT_LOG_DOM
diff --git a/src/lib/evas/include/evas_private.h b/src/lib/evas/include/evas_private.h
index 5ef176f3bc..b6f8c89d63 100644
--- a/src/lib/evas/include/evas_private.h
+++ b/src/lib/evas/include/evas_private.h
@@ -1784,9 +1784,11 @@ void evas_canvas3d_scene_data_fini(Evas_Canvas3D_Scene_Public_Data *data);
1784 1784
1785/* Eet saver/loader functions */ 1785/* Eet saver/loader functions */
1786Evas_Canvas3D_File_Eet *_evas_canvas3d_eet_file_new(void); 1786Evas_Canvas3D_File_Eet *_evas_canvas3d_eet_file_new(void);
1787void _evas_canvas3d_eet_file_init(void); 1787Eet_Data_Descriptor* _evas_canvas3d_eet_file_get();
1788void _evas_canvas3d_eet_descriptor_shutdown(void); 1788void _evas_canvas3d_eet_file_init();
1789void _evas_canvas3d_eet_file_free(void); 1789void _evas_canvas3d_eet_descriptor_shutdown();
1790void _evas_canvas3d_eet_file_free(Evas_Canvas3D_File_Eet* eet_file);
1791
1790 1792
1791/* Filters */ 1793/* Filters */
1792void evas_filter_init(void); 1794void evas_filter_init(void);