[Spice-devel] [PATCH 4/8] Initialize variable to avoid compiler warning

alexl at redhat.com alexl at redhat.com
Wed Sep 29 04:43:06 PDT 2010


From: Alexander Larsson <alexl at redhat.com>

Seems the OSX gcc warns on saveRight not being initialzied.
---
 common/lines.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/common/lines.c b/common/lines.c
index d2e997e..1a14c18 100644
--- a/common/lines.c
+++ b/common/lines.c
@@ -2985,7 +2985,7 @@ miWideDashSegment (GCPtr pGC,
     double L, l;
     double k;
     PolyVertexRec vertices[4];
-    PolyVertexRec saveRight, saveBottom;
+    PolyVertexRec saveRight = { 0 }, saveBottom;
     PolySlopeRec slopes[4];
     PolyEdgeRec left[2], right[2];
     LineFaceRec lcapFace, rcapFace;
-- 
1.7.0.1



More information about the Spice-devel mailing list