From 898833174e33a6494badf03b8499d6ee914905f5 Mon Sep 17 00:00:00 2001 From: curt Date: Fri, 11 Jun 1999 00:25:46 +0000 Subject: [PATCH] Fixed a small bug which cropped up with the new gpc hole interface. --- Tools/Prep/ShapeFile/shape.cxx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Tools/Prep/ShapeFile/shape.cxx b/Tools/Prep/ShapeFile/shape.cxx index 45579cda4..a36ddb8ad 100644 --- a/Tools/Prep/ShapeFile/shape.cxx +++ b/Tools/Prep/ShapeFile/shape.cxx @@ -93,6 +93,7 @@ static void clip_and_write_poly( string root, long int p_index, AreaType area, base.num_contours = 0; base.contour = NULL; + base.hole = NULL; gpc_add_contour( &base, &v_list, 0 ); // FG_LOG( FG_GENERAL, FG_DEBUG, "base = 4 vertices" ); @@ -150,6 +151,7 @@ bool shape_utils_init() { void init_shape(gpc_polygon *shape) { shape->num_contours = 0; shape->contour = NULL; + shape->hole = NULL; } @@ -284,10 +286,12 @@ void process_shape(string path, AreaType area, gpc_polygon *master_gpc_shape) { row.num_contours = 0; row.contour = NULL; + row.hole = NULL; gpc_add_contour( &row, &v_list, 0 ); clip_row.num_contours = 0; clip_row.contour = NULL; + clip_row.hole = NULL; gpc_polygon_clip(GPC_INT, &row, master_gpc_shape, &clip_row);