Skip to content

Commit 7dd02fa

Browse files
authored
Add crash test (#1030)
1 parent 6a4f414 commit 7dd02fa

File tree

1 file changed

+29
-1
lines changed

1 file changed

+29
-1
lines changed

CPP/Tests/TestPolytreeUnion.cpp

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,4 +48,32 @@ TEST(Clipper2Tests, TestPolytreeUnion2) { // #987
4848

4949
ASSERT_EQ(solution.Count(), 1);
5050
EXPECT_EQ(solution[0]->Count(), 1);
51-
}
51+
}
52+
53+
TEST(Clipper2Tests, TestPolytreeUnion3)
54+
{
55+
Paths64 subject;
56+
subject.push_back(MakePath({
57+
-120927680, 590077597,
58+
-120919386, 590077307,
59+
-120919432, 590077309,
60+
-120919451, 590077309,
61+
-120919455, 590077310,
62+
-120099297, 590048669,
63+
-120928004, 590077608,
64+
-120902794, 590076728,
65+
-120919444, 590077309,
66+
-120919450, 590077309,
67+
-120919842, 590077323,
68+
-120922852, 590077428,
69+
-120902452, 590076716,
70+
-120902455, 590076716,
71+
-120912590, 590077070,
72+
11914491, 249689797
73+
}));
74+
75+
Clipper64 clipper;
76+
clipper.AddSubject(subject);
77+
Clipper2Lib::PolyTree64 solution;
78+
clipper.Execute(ClipType::Union, FillRule::EvenOdd, solution);
79+
}

0 commit comments

Comments
 (0)