From 23156f0abe0242c715bc24f43a17590d23f99242 Mon Sep 17 00:00:00 2001 From: Alessandro Ranellucci Date: Sun, 19 Feb 2012 17:18:50 +0100 Subject: [PATCH] Fix slicing error. #180 --- lib/Slic3r/TriangleMesh.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/Slic3r/TriangleMesh.pm b/lib/Slic3r/TriangleMesh.pm index fb5d22c92..7e245425f 100644 --- a/lib/Slic3r/TriangleMesh.pm +++ b/lib/Slic3r/TriangleMesh.pm @@ -207,6 +207,7 @@ sub make_loops { my $next_line; if (defined $line->next_facet_index) { for (@lines) { + next if $visited_lines{$_}; if ($_->facet_index == $line->next_facet_index) { $next_line = $_; last; @@ -215,6 +216,7 @@ sub make_loops { } elsif (defined $line->b_id) { for (@lines) { next if !defined $_->a_id; + next if $visited_lines{$_}; if ($_->a_id == $line->b_id) { $next_line = $_; last;