stefan pushed a commit to branch master.

http://git.enlightenment.org/core/elementary.git/commit/?id=243dfb008d4b19d446ae4a3f8e2b7d2dd7fb04c2

commit 243dfb008d4b19d446ae4a3f8e2b7d2dd7fb04c2
Author: Stefan Schmidt <ste...@osg.samsung.com>
Date:   Mon Nov 30 15:37:10 2015 +0100

    test_gesture_layer: correct argument order for calloc()
    
    calloc() expects count first and the actual size to allocate as second
    argument. Say Thank You to smatch for finding this issues for us.
---
 src/bin/test_gesture_layer.c  | 2 +-
 src/bin/test_gesture_layer3.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/bin/test_gesture_layer.c b/src/bin/test_gesture_layer.c
index 8179267..5f75e6f 100644
--- a/src/bin/test_gesture_layer.c
+++ b/src/bin/test_gesture_layer.c
@@ -359,7 +359,7 @@ test_gesture_layer(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED,
    char buf[PATH_MAX];
    int ind = 0;
    Photo_Object **photo_array;
-   photo_array = calloc(sizeof(*photo_array), 4);
+   photo_array = calloc(4, sizeof(*photo_array));
 
    w = 480;
    h = 800;
diff --git a/src/bin/test_gesture_layer3.c b/src/bin/test_gesture_layer3.c
index 8f08239..9d89ca9 100644
--- a/src/bin/test_gesture_layer3.c
+++ b/src/bin/test_gesture_layer3.c
@@ -558,7 +558,7 @@ test_gesture_layer3(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED,
    char buf[PATH_MAX];
    int ind = 0;
    Photo_Object **photo_array;
-   photo_array = calloc(sizeof(*photo_array), 4);
+   photo_array = calloc(4, sizeof(*photo_array));
 
    w = 480;
    h = 800;

-- 


Reply via email to