[PATCH:xkbcomp 3/4] Remove useless assignment to 'outline' variable

Alan Coopersmith alan.coopersmith at oracle.com
Sat Mar 8 19:10:27 PST 2014


Flagged by cppcheck 1.64:
[app/xkbcomp/geometry.c:2426] -> [app/xkbcomp/geometry.c:2427]:
 (performance) Variable 'outline' is reassigned a value before
               the old one has been used.

Signed-off-by: Alan Coopersmith <alan.coopersmith at oracle.com>
---
 geometry.c |    1 -
 1 file changed, 1 deletion(-)

diff --git a/geometry.c b/geometry.c
index 2daa213..5d65316 100644
--- a/geometry.c
+++ b/geometry.c
@@ -2423,7 +2423,6 @@ HandleShapeBody(ShapeDef * def, ShapeInfo * si, unsigned merge,
                           ol->points, info);
             continue;
         }
-        outline = NULL;
         outline = &si->outlines[nOut++];
         outline->num_points = ol->nPoints;
         outline->corner_radius = si->dfltCornerRadius;
-- 
1.7.9.2



More information about the xorg-devel mailing list