xartigas pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=8a617fda979d1522a880f3e57d2e1adfc9f20814

commit 8a617fda979d1522a880f3e57d2e1adfc9f20814
Author: Jérémy Zurcher <jer...@asynk.ch>
Date:   Tue Dec 18 13:01:34 2018 +0100

    silence most left over compiler warnings
    
    Summary: silence -Wshadow -Wunused-variable -Wunused-parameter
    
    Reviewers: segfaultxavi
    
    Reviewed By: segfaultxavi
    
    Subscribers: segfaultxavi, cedric, #reviewers, #committers
    
    Tags: #efl
    
    Differential Revision: https://phab.enlightenment.org/D7473
---
 src/bin/elementary/quicklaunch.c              | 6 +++---
 src/bin/elementary/test_glview.c              | 2 +-
 src/bin/elementary/test_glview_manygears.c    | 2 +-
 src/lib/ecore/efl_model_composite_selection.c | 1 -
 src/lib/edje/edje_calc.c                      | 2 +-
 src/lib/elementary/elm_focus_legacy.c         | 6 +++---
 src/lib/elementary/elm_gengrid.c              | 8 ++++----
 src/lib/elementary/elm_genlist.c              | 4 ++--
 src/lib/elementary/elm_interface_scrollable.c | 2 +-
 src/lib/evas/canvas/efl_canvas_vg_object.c    | 1 -
 src/lib/evas/canvas/evas_object_textblock.c   | 4 ++--
 11 files changed, 18 insertions(+), 20 deletions(-)

diff --git a/src/bin/elementary/quicklaunch.c b/src/bin/elementary/quicklaunch.c
index 96bbcda112..3e7598e6c2 100644
--- a/src/bin/elementary/quicklaunch.c
+++ b/src/bin/elementary/quicklaunch.c
@@ -347,10 +347,10 @@ main(int argc, char **argv)
      {
         int fd;
         struct sockaddr_un client;
-        socklen_t len;
+        socklen_t slen;
 
-        len = sizeof(struct sockaddr_un);
-        fd = accept(sock, (struct sockaddr *)&client, &len);
+        slen = sizeof(struct sockaddr_un);
+        fd = accept(sock, (struct sockaddr *)&client, &slen);
 
         DBG("Accepting connection.");
         elm_quicklaunch_sub_init(argc, argv);
diff --git a/src/bin/elementary/test_glview.c b/src/bin/elementary/test_glview.c
index 6a133e9fd0..8df1fddc8d 100644
--- a/src/bin/elementary/test_glview.c
+++ b/src/bin/elementary/test_glview.c
@@ -249,7 +249,7 @@ draw_gear(GLData *gld, Gear *gear, GLfloat *m,
    gl->glVertexAttribPointer(0, 3, GL_FLOAT, GL_FALSE,
                              6 * sizeof(GLfloat), NULL);
    gl->glVertexAttribPointer(1, 3, GL_FLOAT, GL_FALSE,
-                             6 * sizeof(GLfloat), (GLfloat *) 0 + 3);
+                             6 * sizeof(GLfloat), (GLfloat *)(0 + 3 * 
sizeof(GLfloat *)));
    gl->glEnableVertexAttribArray(0);
    gl->glEnableVertexAttribArray(1);
    gl->glDrawArrays(GL_TRIANGLE_STRIP, 0, gear->count);
diff --git a/src/bin/elementary/test_glview_manygears.c 
b/src/bin/elementary/test_glview_manygears.c
index 17e05585a9..6161341325 100644
--- a/src/bin/elementary/test_glview_manygears.c
+++ b/src/bin/elementary/test_glview_manygears.c
@@ -461,7 +461,7 @@ draw_gear(GLData *gld, Gear *gear, GLfloat *transform,
 
    // Set up the position of the attributes in the vertex buffer object
    gl->glVertexAttribPointer(0, 3, GL_FLOAT, GL_FALSE, 6 * sizeof(GLfloat), 
NULL);
-   gl->glVertexAttribPointer(1, 3, GL_FLOAT, GL_FALSE, 6 * sizeof(GLfloat), 
(GLfloat *) 0 + 3);
+   gl->glVertexAttribPointer(1, 3, GL_FLOAT, GL_FALSE, 6 * sizeof(GLfloat), 
(GLfloat *)(0 + 3 * sizeof(GLfloat *)));
 
    // Enable the attributes
    gl->glEnableVertexAttribArray(0);
diff --git a/src/lib/ecore/efl_model_composite_selection.c 
b/src/lib/ecore/efl_model_composite_selection.c
index ad14b74275..18db24cfc3 100644
--- a/src/lib/ecore/efl_model_composite_selection.c
+++ b/src/lib/ecore/efl_model_composite_selection.c
@@ -380,7 +380,6 @@ 
_efl_model_composite_selection_children_efl_model_property_set(Eo *obj,
              Eo *parent;
              Eina_Value *vs;
              unsigned long selected = 0;
-             Eina_Bool success;
 
              // In this case we need to first unselect the previously selected 
one
              // and then commit the change to this one.
diff --git a/src/lib/edje/edje_calc.c b/src/lib/edje/edje_calc.c
index 5877ebb6ed..a050edcdca 100644
--- a/src/lib/edje/edje_calc.c
+++ b/src/lib/edje/edje_calc.c
@@ -3836,7 +3836,7 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int 
flags, Edje_Calc_Params *sta
    Edje_Real_Part *confine_to = NULL;
    Edje_Real_Part *threshold = NULL;
    FLOAT_T pos = ZERO, pos2;
-   Edje_Calc_Params lp3 = { 0 };
+   Edje_Calc_Params lp3 = { { 0 } };
    Evas_Coord mmw = 0, mmh = 0;
    Eina_Bool map_colors_free = EINA_FALSE;
 
diff --git a/src/lib/elementary/elm_focus_legacy.c 
b/src/lib/elementary/elm_focus_legacy.c
index fdf6b4e2a5..31e1c32db1 100644
--- a/src/lib/elementary/elm_focus_legacy.c
+++ b/src/lib/elementary/elm_focus_legacy.c
@@ -174,7 +174,7 @@ elm_object_focus_cycle(Evas_Object        *obj,
 }
 
 static Evas_Object*
-_get_legacy_target(Evas_Object *eo, Elm_Widget_Smart_Data *pd, 
Elm_Focus_Direction dir)
+_get_legacy_target(EINA_UNUSED Evas_Object *eo, Elm_Widget_Smart_Data *pd, 
Elm_Focus_Direction dir)
 {
    Evas_Object *result = NULL;
 
@@ -245,8 +245,8 @@ elm_object_focus_next(Evas_Object        *obj,
                {
                   Evas_Object *parent = eina_array_data_get(old_chain, i);
                   if (!elm_widget_is(parent)) continue;
-                  ELM_WIDGET_DATA_GET_OR_RETURN(parent, pd);
-                  legacy_target = _get_legacy_target(parent, pd, dir);
+                  ELM_WIDGET_DATA_GET_OR_RETURN(parent, ppd);
+                  legacy_target = _get_legacy_target(parent, ppd, dir);
                   if (legacy_target) break;
                }
              eina_array_free(new_chain);
diff --git a/src/lib/elementary/elm_gengrid.c b/src/lib/elementary/elm_gengrid.c
index ba710210b0..f321edf9bb 100644
--- a/src/lib/elementary/elm_gengrid.c
+++ b/src/lib/elementary/elm_gengrid.c
@@ -4248,8 +4248,8 @@ _elm_gengrid_efl_ui_focus_manager_setup_on_first_touch(Eo 
*obj, Elm_Gengrid_Data
                elm_gengrid_item_selected_set(eo_it, EINA_TRUE);
              else
                {
-                  ELM_GENGRID_ITEM_DATA_GET(eo_it, pd);
-                  if (pd->realized)
+                  ELM_GENGRID_ITEM_DATA_GET(eo_it, pd_it);
+                  if (pd_it->realized)
                     efl_ui_focus_manager_focus_set(obj, eo_it);
                }
           }
@@ -4261,7 +4261,7 @@ _elm_gengrid_efl_ui_focus_manager_setup_on_first_touch(Eo 
*obj, Elm_Gengrid_Data
 }
 
 static Efl_Ui_Focus_Object*
-_select_candidate(Eo *obj, Elm_Gengrid_Data *pd, Efl_Ui_Focus_Direction 
direction)
+_select_candidate(Eo *obj, EINA_UNUSED Elm_Gengrid_Data *pd, 
Efl_Ui_Focus_Direction direction)
 {
    Elm_Object_Item *first = elm_gengrid_first_item_get(obj);
    Elm_Object_Item *last = elm_gengrid_last_item_get(obj);
@@ -4304,7 +4304,7 @@ _elm_gengrid_efl_ui_focus_manager_move(Eo *obj, 
Elm_Gengrid_Data *pd, Efl_Ui_Foc
 }
 
 EOLIAN static Efl_Ui_Focus_Object*
-_elm_gengrid_efl_ui_focus_manager_manager_focus_get(const Eo *obj, 
Elm_Gengrid_Data *pd)
+_elm_gengrid_efl_ui_focus_manager_manager_focus_get(const Eo *obj, EINA_UNUSED 
Elm_Gengrid_Data *pd)
 {
    Eo *focused_obj = efl_ui_focus_manager_focus_get(efl_super(obj, MY_CLASS));
    Eo *registered_manager = efl_ui_focus_object_focus_manager_get(obj);
diff --git a/src/lib/elementary/elm_genlist.c b/src/lib/elementary/elm_genlist.c
index 0ad79d137a..0e7b3a47a1 100644
--- a/src/lib/elementary/elm_genlist.c
+++ b/src/lib/elementary/elm_genlist.c
@@ -3444,7 +3444,7 @@ _elm_genlist_efl_ui_focus_manager_setup_on_first_touch(Eo 
*obj, Elm_Genlist_Data
 }
 
 EOLIAN static Efl_Ui_Focus_Object*
-_elm_genlist_efl_ui_focus_manager_manager_focus_get(const Eo *obj, 
Elm_Genlist_Data *pd)
+_elm_genlist_efl_ui_focus_manager_manager_focus_get(const Eo *obj, EINA_UNUSED 
Elm_Genlist_Data *pd)
 {
    Eo *focused_obj = efl_ui_focus_manager_focus_get(efl_super(obj, MY_CLASS));
    Eo *registered_manager = efl_ui_focus_object_focus_manager_get(obj);
@@ -3456,7 +3456,7 @@ _elm_genlist_efl_ui_focus_manager_manager_focus_get(const 
Eo *obj, Elm_Genlist_D
 }
 
 static Efl_Ui_Focus_Object*
-_select_candidate(Eo *obj, Elm_Genlist_Data *pd, Efl_Ui_Focus_Direction 
direction)
+_select_candidate(Eo *obj, EINA_UNUSED Elm_Genlist_Data *pd, 
Efl_Ui_Focus_Direction direction)
 {
    Elm_Object_Item *first = elm_genlist_first_item_get(obj);
    Elm_Object_Item *last = elm_genlist_last_item_get(obj);
diff --git a/src/lib/elementary/elm_interface_scrollable.c 
b/src/lib/elementary/elm_interface_scrollable.c
index 3bfac1e625..0e666236fc 100644
--- a/src/lib/elementary/elm_interface_scrollable.c
+++ b/src/lib/elementary/elm_interface_scrollable.c
@@ -2675,7 +2675,7 @@ _elm_scroll_momentum_calc(int dx, int dy, double dt, 
double *vx, double *vy, int
    fvel_y = vel_y * (1/60.0);
    fvel = vel * (1/60.0);
 
-   if (abs(fvel) < _elm_config->thumbscroll_threshold ) return EINA_FALSE;
+   if (abs((int) fvel) < _elm_config->thumbscroll_threshold ) return 
EINA_FALSE;
 
    // calculate a number of frames to reach min_px when it follows a geometric 
sequence with scale factor r
    n = log(min_px/fvel) / log(r);
diff --git a/src/lib/evas/canvas/efl_canvas_vg_object.c 
b/src/lib/evas/canvas/efl_canvas_vg_object.c
index ac45c6d791..b2352aaebe 100644
--- a/src/lib/evas/canvas/efl_canvas_vg_object.c
+++ b/src/lib/evas/canvas/efl_canvas_vg_object.c
@@ -259,7 +259,6 @@ EOLIAN static Eina_Bool
 _efl_canvas_vg_object_efl_file_file_set(Eo *eo_obj, Efl_Canvas_Vg_Object_Data 
*pd, const char *file, const char *key)
 {
    Vg_Cache_Entry *old_entry;
-   int w, h;
 
    if (!file) return EINA_FALSE;
 
diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 71fb0e53c5..644aa79d80 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -5564,7 +5564,7 @@ _layout_item_obstacle_get(Ctxt *c, 
Evas_Object_Textblock_Item *it);
 static int
 _layout_par(Ctxt *c)
 {
-   Evas_Object_Textblock_Item *it, *prev_it;
+   Evas_Object_Textblock_Item *it;
    Eina_List *i;
    int ret = 0;
    int wrap = -1;
@@ -5681,8 +5681,8 @@ _layout_par(Ctxt *c)
         int redo_item = 0;
         Evas_Textblock_Obstacle_Info *obs_info = NULL;
         Evas_Coord itw;
+        Evas_Object_Textblock_Item *prev_it = it;
 
-        prev_it = it;
         it = _ITEM(eina_list_data_get(i));
         /* Skip visually deleted items */
         if (it->visually_deleted ||

-- 


Reply via email to