From 30852dd99b28fddaef4ac37bfa225da343c6be7e Mon Sep 17 00:00:00 2001 From: lecoanet Date: Mon, 23 Feb 2004 10:42:33 +0000 Subject: Fixed an uninitialized controls pointer leading to unexepected behavior when adding a contour from a curve item --- generic/Geo.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'generic') diff --git a/generic/Geo.c b/generic/Geo.c index 5a284c1..ed33e4b 100644 --- a/generic/Geo.c +++ b/generic/Geo.c @@ -59,6 +59,7 @@ ZnPolyContour1(ZnPoly *poly, poly->contour1.num_points = num_pts; poly->contour1.points = pts; poly->contour1.cw = cw; + poly->contour1.controls = NULL; } void @@ -86,6 +87,9 @@ ZnPolyFree(ZnPoly *poly) unsigned int i; for (i = 0; i < poly->num_contours; i++) { ZnFree(poly->contours[i].points); +/* if (poly->contours[i].controls) { + ZnFree(poly->contours[i].controls); + }*/ } if ((poly->contours != &poly->contour1) && (poly->num_contours > 1)) { -- cgit v1.1