[GRASS-SVN] r57842 - grass/trunk/lib/gis

svn_grass at osgeo.org svn_grass at osgeo.org
Thu Sep 26 03:24:36 PDT 2013


Author: mmetz
Date: 2013-09-26 03:24:36 -0700 (Thu, 26 Sep 2013)
New Revision: 57842

Modified:
   grass/trunk/lib/gis/plot.c
Log:
libgis: fix FPE error tolerance for plotting

Modified: grass/trunk/lib/gis/plot.c
===================================================================
--- grass/trunk/lib/gis/plot.c	2013-09-26 05:40:12 UTC (rev 57841)
+++ grass/trunk/lib/gis/plot.c	2013-09-26 10:24:36 UTC (rev 57842)
@@ -450,7 +450,7 @@
 
     /* check if perimeter has odd number of points */
     if (st->np & 1) {
-	G_debug(1, "Weird internal error: perimeter has odd number of points");
+	G_warning("Weird internal error: perimeter has odd number of points");
 	return OUT_OF_SYNC;
     }
 
@@ -460,7 +460,7 @@
     /* plot */
     for (i = 1; i < st->np; i += 2) {
 	if (st->P[i].y != st->P[i - 1].y) {
-	    G_debug(1, "Weird internal error: edge leaves row");
+	    G_warning("Weird internal error: edge leaves row");
 	    return OUT_OF_SYNC;
 	}
 	st->row_fill(st->P[i].y, st->P[i - 1].x + shift1, st->P[i].x + shift1);
@@ -586,7 +586,7 @@
 
     /* check if perimeter has odd number of points */
     if (st->np & 1) {
-	G_debug(1, "Weird internal error: perimeter has odd number of points");
+	G_warning("Weird internal error: perimeter has odd number of points");
 	return OUT_OF_SYNC;
     }
 
@@ -597,7 +597,7 @@
     for (j = 0; j < rings; j++) {
 	for (i = 1; i < st->np; i += 2) {
 	    if (st->P[i].y != st->P[i - 1].y) {
-		G_debug(1, "Weird internal error: edge leaves row");
+		G_warning("Weird internal error: edge leaves row");
 		return OUT_OF_SYNC;
 	    }
 	    st->row_fill(st->P[i].y, st->P[i - 1].x + shift1[j], st->P[i].x + shift1[j]);
@@ -641,7 +641,7 @@
 	    d = fabs(y1);
 
 	d = frexp(d, &exp);
-	exp -= 52;
+	exp -= 53;
 	d = ldexp(d, exp);
     }
 



More information about the grass-commit mailing list