Skip to content

Commit a082aed

Browse files
committed
Remove remaining GEODEBUG references from geo_ops.c
Commit a7dc63d removed most of the GEODEBUG occurrences, but there were a couple remaining. So remove them too, to get rid of the macro entirely. Author: Emre Hasegeli Discussion: https://www.postgresql.org/message-id/CAE2gYzxF7-5djV6-cEvqQu-fNsnt%3DEqbOURx7ZDg%2BVv6ZMTWbg%40mail.gmail.com
1 parent e1d19c9 commit a082aed

File tree

1 file changed

+0
-27
lines changed

1 file changed

+0
-27
lines changed

src/backend/utils/adt/geo_ops.c

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -2423,22 +2423,14 @@ dist_ppoly_internal(Point *pt, POLYGON *poly)
24232423
LSEG seg;
24242424

24252425
if (point_inside(pt, poly->npts, poly->p) != 0)
2426-
{
2427-
#ifdef GEODEBUG
2428-
printf("dist_ppoly_internal- point inside of polygon\n");
2429-
#endif
24302426
return 0.0;
2431-
}
24322427

24332428
/* initialize distance with segment between first and last points */
24342429
seg.p[0].x = poly->p[0].x;
24352430
seg.p[0].y = poly->p[0].y;
24362431
seg.p[1].x = poly->p[poly->npts - 1].x;
24372432
seg.p[1].y = poly->p[poly->npts - 1].y;
24382433
result = lseg_closept_point(NULL, &seg, pt);
2439-
#ifdef GEODEBUG
2440-
printf("dist_ppoly_internal- segment 0/n distance is %f\n", result);
2441-
#endif
24422434

24432435
/* check distances for other segments */
24442436
for (i = 0; i < poly->npts - 1; i++)
@@ -2448,9 +2440,6 @@ dist_ppoly_internal(Point *pt, POLYGON *poly)
24482440
seg.p[1].x = poly->p[i + 1].x;
24492441
seg.p[1].y = poly->p[i + 1].y;
24502442
d = lseg_closept_point(NULL, &seg, pt);
2451-
#ifdef GEODEBUG
2452-
printf("dist_ppoly_internal- segment %d distance is %f\n", (i + 1), d);
2453-
#endif
24542443
if (d < result)
24552444
result = d;
24562445
}
@@ -5233,16 +5222,8 @@ plist_same(int npts, Point *p1, Point *p2)
52335222
if (j >= npts)
52345223
j = 0;
52355224
if (!point_eq_point(&p2[j], &p1[ii]))
5236-
{
5237-
#ifdef GEODEBUG
5238-
printf("plist_same- %d failed forward match with %d\n", j, ii);
5239-
#endif
52405225
break;
5241-
}
52425226
}
5243-
#ifdef GEODEBUG
5244-
printf("plist_same- ii = %d/%d after forward match\n", ii, npts);
5245-
#endif
52465227
if (ii == npts)
52475228
return true;
52485229

@@ -5252,16 +5233,8 @@ plist_same(int npts, Point *p1, Point *p2)
52525233
if (j < 0)
52535234
j = (npts - 1);
52545235
if (!point_eq_point(&p2[j], &p1[ii]))
5255-
{
5256-
#ifdef GEODEBUG
5257-
printf("plist_same- %d failed reverse match with %d\n", j, ii);
5258-
#endif
52595236
break;
5260-
}
52615237
}
5262-
#ifdef GEODEBUG
5263-
printf("plist_same- ii = %d/%d after reverse match\n", ii, npts);
5264-
#endif
52655238
if (ii == npts)
52665239
return true;
52675240
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy