[postgis-tickets] r17007 - Un-break build with debug logs
Raul
raul at rmr.ninja
Tue Nov 13 02:49:07 PST 2018
Author: algunenano
Date: 2018-11-13 02:49:06 -0800 (Tue, 13 Nov 2018)
New Revision: 17007
Modified:
trunk/liblwgeom/lwstroke.c
trunk/postgis/gserialized_spgist_2d.c
Log:
Un-break build with debug logs
Related to #4235
Modified: trunk/liblwgeom/lwstroke.c
===================================================================
--- trunk/liblwgeom/lwstroke.c 2018-11-13 10:47:14 UTC (rev 17006)
+++ trunk/liblwgeom/lwstroke.c 2018-11-13 10:49:06 UTC (rev 17007)
@@ -178,8 +178,11 @@
if ( maxErr > radius * 2 )
{
maxErr = radius * 2;
- LWDEBUGF(2, "lwarc_linearize: tolerance %g is too big, "
- "using arc-max 2 * radius == %g", tol, maxErr);
+ LWDEBUGF(2,
+ "lwarc_linearize: tolerance %g is too big, "
+ "using arc-max 2 * radius == %g",
+ max_deviation,
+ maxErr);
}
do {
halfAngle = acos( 1.0 - maxErr / radius );
@@ -191,7 +194,13 @@
maxErr *= 2;
} while(1);
increment = 2 * halfAngle;
- LWDEBUGF(2, "lwarc_linearize: maxDiff:%g, radius:%g, halfAngle:%g, increment:%g (%g degrees)", tol, radius, halfAngle, increment, increment*180/M_PI);
+ LWDEBUGF(2,
+ "lwarc_linearize: maxDiff:%g, radius:%g, halfAngle:%g, increment:%g (%g degrees)",
+ max_deviation,
+ radius,
+ halfAngle,
+ increment,
+ increment * 180 / M_PI);
return increment;
}
@@ -337,12 +346,11 @@
}
if ( flags & LW_LINEARIZE_FLAG_SYMMETRIC )
- {{
- LWDEBUGF(2, "lwarc_linearize SYMMETRIC requested - total angle %g deg",
- angle * 180 / M_PI);
+ {
+ LWDEBUGF(2, "lwarc_linearize SYMMETRIC requested - total angle %g deg", total_angle * 180 / M_PI);
if ( flags & LW_LINEARIZE_FLAG_RETAIN_ANGLE )
- {{
+ {
/* Number of complete steps */
int steps = trunc(total_angle / increment);
@@ -360,9 +368,9 @@
"total angle %g, steps %d, increment %g, remainder %g",
total_angle * 180 / M_PI, steps, increment * 180 / M_PI,
angle_remainder * 180 / M_PI);
- }}
+ }
else
- {{
+ {
/* Number of segments in output */
int segs = ceil(total_angle / increment);
/* Tweak increment to be regular for all the arc */
@@ -372,8 +380,8 @@
"total angle %g degrees - LINESTRING(%g %g,%g %g,%g %g) - S:%d - I:%g",
total_angle*180/M_PI, p1->x, p1->y, center.x, center.y, p3->x, p3->y,
segs, increment*180/M_PI);
- }}
- }}
+ }
+ }
/* p2 on left side => clockwise sweep */
if ( clockwise )
Modified: trunk/postgis/gserialized_spgist_2d.c
===================================================================
--- trunk/postgis/gserialized_spgist_2d.c 2018-11-13 10:47:14 UTC (rev 17006)
+++ trunk/postgis/gserialized_spgist_2d.c 2018-11-13 10:49:06 UTC (rev 17007)
@@ -679,8 +679,6 @@
PG_RETURN_POINTER(bbox_out);
}
- POSTGIS_DEBUGF(4, "[SPGIST] got box: %s", box2df_to_string(bbox_out));
-
/* Check all the dimensions for finite values */
if ((!isfinite(bbox_out->xmax) || !isfinite(bbox_out->xmin)) ||
(!isfinite(bbox_out->ymax) || !isfinite(bbox_out->ymin)))
More information about the postgis-tickets
mailing list