discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=877d35e36116354addca99bf8875c03fee3309cb

commit 877d35e36116354addca99bf8875c03fee3309cb
Author: Mike Blumenkrantz <zm...@osg.samsung.com>
Date:   Thu Mar 12 15:49:59 2015 -0400

    ecore-wl use calloc for Ecore_Wl_Input allocation instead of malloc+memset
---
 src/lib/ecore_wayland/ecore_wl_input.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/src/lib/ecore_wayland/ecore_wl_input.c 
b/src/lib/ecore_wayland/ecore_wl_input.c
index c91e6b7..ffd382e 100644
--- a/src/lib/ecore_wayland/ecore_wl_input.c
+++ b/src/lib/ecore_wayland/ecore_wl_input.c
@@ -381,9 +381,7 @@ _ecore_wl_input_add(Ecore_Wl_Display *ewd, unsigned int id)
 
    LOGFN(__FILE__, __LINE__, __FUNCTION__);
 
-   if (!(input = malloc(sizeof(Ecore_Wl_Input)))) return;
-
-   memset(input, 0, sizeof(Ecore_Wl_Input));
+   if (!(input = calloc(1, sizeof(Ecore_Wl_Input)))) return;
 
    input->display = ewd;
    input->pointer_focus = NULL;

-- 


Reply via email to