From c02dcf696614556b49b6e65b94f1471759e9aa77 Mon Sep 17 00:00:00 2001 From: Stefan Schmidt Date: Fri, 20 Sep 2019 10:36:17 +0200 Subject: [PATCH] efl_ui_textpath: make sure variables are not uses uninitialized First and last could have been uninitialized for their first use in some cases. Make sure we set the x y coordinates to 0 to begin with. Coverity IDs: 1401458, 1404747 Reviewed-by: Mike Blumenkrantz Differential Revision: https://phab.enlightenment.org/D10044 --- src/lib/elementary/efl_ui_textpath.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lib/elementary/efl_ui_textpath.c b/src/lib/elementary/efl_ui_textpath.c index 2f9515840c..a3bac40522 100644 --- a/src/lib/elementary/efl_ui_textpath.c +++ b/src/lib/elementary/efl_ui_textpath.c @@ -577,7 +577,8 @@ _path_start_angle_adjust(Eo *obj, Efl_Ui_Textpath_Data *pd) { Eina_Rect r; Efl_Ui_Textpath_Segment *seg; - Eina_Vector2 first, last; + Eina_Vector2 first = { 0, 0 }; + Eina_Vector2 last = { 0, 0 }; int remained_w, len; double rad, t, offset_angle;