projects
/
platform
/
upstream
/
efl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c656332
)
ecore-wayland: Check return of calloc
author
Chris Michael
<cp.michael@samsung.com>
Wed, 13 Aug 2014 14:50:04 +0000
(10:50 -0400)
committer
Chris Michael
<cp.michael@samsung.com>
Wed, 1 Oct 2014 20:15:37 +0000
(16:15 -0400)
Calloc 'can' fail so lets check the return and make sure 'global' is
valid else we will segfault.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
src/lib/ecore_wayland/ecore_wl.c
patch
|
blob
|
history
diff --git
a/src/lib/ecore_wayland/ecore_wl.c
b/src/lib/ecore_wayland/ecore_wl.c
index
4a634cd
..
5a21932
100644
(file)
--- a/
src/lib/ecore_wayland/ecore_wl.c
+++ b/
src/lib/ecore_wayland/ecore_wl.c
@@
-610,7
+610,7
@@
_ecore_wl_cb_handle_global(void *data, struct wl_registry *registry, unsigned in
ewd = data;
-
global = calloc(1, sizeof(Ecore_Wl_Global))
;
+
if (!(global = calloc(1, sizeof(Ecore_Wl_Global)))) return
;
global->id = id;
global->interface = strdup(interface);