Browse Source

v.buffer: fix bug introduced in https://trac.osgeo.org/grass/changeset/65715

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@65759 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa 9 years ago
parent
commit
82cfc2806f
1 changed files with 6 additions and 4 deletions
  1. 6 4
      vector/v.buffer/geos.c

+ 6 - 4
vector/v.buffer/geos.c

@@ -147,7 +147,7 @@ int geos_buffer(struct Map_info *In, struct Map_info *Out,
     GEOSGeometry *IGeom = NULL;
     GEOSGeometry *OGeom = NULL;
     
-    G_debug(3, "geos_buffer()");
+    G_debug(3, "geos_buffer(): id=%d", id);
 
     if (type == GV_AREA)
 	IGeom = Vect_read_area_geos(In, id);
@@ -167,13 +167,15 @@ int geos_buffer(struct Map_info *In, struct Map_info *Out,
         OGeom = GEOSBufferWithParams(IGeom, geos_params, da);
         GEOSBufferParams_destroy(geos_params);
     }
-    else
-#else
+    else {
         OGeom = GEOSBuffer(IGeom, da, 12);
+    }
+#else
+    OGeom = GEOSBuffer(IGeom, da, 12);
 #endif
     
     if (!OGeom) {
-	G_fatal_error(_("Buffering failed"));
+        G_fatal_error(_("Buffering failed (feature %d)"), id);
     }
     
     geom2ring(OGeom, Out, Buf, si, Cats, arr_bc, buffers_count, arr_bc_alloc);