From 844524a817cb687c3e81a9a10341d60b329ff317 Mon Sep 17 00:00:00 2001 From: Daniel Juyung Seo Date: Sun, 2 Feb 2014 23:14:23 +0900 Subject: [PATCH] test: Initialize structure on declarations with { 0 }. No need to call memset manually. --- src/bin/test_flip_page.c | 4 +--- src/bin/test_focus3.c | 3 +-- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/bin/test_flip_page.c b/src/bin/test_flip_page.c index 555ddd4..5e0201c 100644 --- a/src/bin/test_flip_page.c +++ b/src/bin/test_flip_page.c @@ -514,9 +514,7 @@ _state_update(State *st) for (row = 0, gy = 0; gy < h; gy += gszh, row++) { - Vertex3 vo[4]; - - memset(vo, 0, sizeof (vo)); + Vertex3 vo[4] = { 0 }; if (b > 0) nn = num + st->slices_h - row - 1; else nn = num + row; diff --git a/src/bin/test_focus3.c b/src/bin/test_focus3.c index 9edb1c7..207327f 100644 --- a/src/bin/test_focus3.c +++ b/src/bin/test_focus3.c @@ -364,9 +364,8 @@ void test_focus_custom(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED) { Evas_Object *win, *fr, *bx, *bx2, *bt, *spinner, *sp, *chk; - char win_focus_theme[PATH_MAX]; + char win_focus_theme[PATH_MAX] = { 0 }; - memset(win_focus_theme, 0, sizeof(win_focus_theme)); sprintf(win_focus_theme, "%s/objects/test_focus_custom.edj", elm_app_data_dir_get()); elm_theme_overlay_add(NULL, win_focus_theme); -- 2.7.4