[GRASS-SVN] r49172 - grass/trunk/display/d.vect

svn_grass at osgeo.org svn_grass at osgeo.org
Thu Nov 10 10:40:24 EST 2011


Author: mmetz
Date: 2011-11-10 07:40:23 -0800 (Thu, 10 Nov 2011)
New Revision: 49172

Modified:
   grass/trunk/display/d.vect/attr.c
Log:
martinl: fix #1184

Modified: grass/trunk/display/d.vect/attr.c
===================================================================
--- grass/trunk/display/d.vect/attr.c	2011-11-10 15:26:24 UTC (rev 49171)
+++ grass/trunk/display/d.vect/attr.c	2011-11-10 15:40:23 UTC (rev 49172)
@@ -47,12 +47,10 @@
     Vect_rewind(Map);
     while (1) {
 	ltype = Vect_read_next_line(Map, Points, Cats);
-	switch (ltype) {
-	case -1:
+	if (ltype == -1)
 	    G_fatal_error(_("Unable to read vector map"));
-	case -2:		/* EOF */
-	    return 0;
-	}
+	else if (ltype == -2)		/* EOF */
+	    break;
 
 	if (!(type & ltype) && !((type & GV_AREA) && (ltype & GV_CENTROID)))
 	    continue;		/* used for both lines and labels */



More information about the grass-commit mailing list