summaryrefslogtreecommitdiff
path: root/math/gnuplot+/files/patch-xc
blob: 43b861cb924aa6485e6f372d3e3fae2da2cd8b09 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# hidden3d-endlessloop
--- hidden3d.c.ORIG	Thu Aug 19 15:39:28 1999
+++ hidden3d.c	Wed Nov 17 17:42:00 1999
@@ -2140,14 +2140,20 @@
 	    test->tested = is_moved_or_split;
 	    SPLIT_TEST_BY_P;
 	} else {
-	    if (loop && (p->tested == is_tested)) {
-		/* Ouch, seems like we're in trouble, really */
+	    if (loop && (p->tested == is_in_loop)) { 
+		/* Ouch, seems like we're in trouble, really: no way to
+		 * split one of them, and we're in a loop, so we can't
+		 * move p to the front of the list, without risking an
+		 * endless loop. Well, let's just output the darn thing,
+		 * then, no matter what. :-( */
+#if DEBUG /* normally off */
 		fprintf(stderr, "\
 #Failed: In loop, without intersections.\n\
 #Relations are %d, %d\n",
 			p_rel_tplane, t_rel_pplane);
 		print_polygon(test, "test");
 		print_polygon(p, "p");
+#endif	
 		continue;	/* Keep quiet, maybe no-one will notice (;-) */
 	    } else {
 		PUT_P_IN_FRONT_TEST(is_in_loop);