From: Mikko Rasa Date: Sun, 12 Aug 2012 15:53:52 +0000 (+0300) Subject: Fix bugs that crept in with refactoring X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=95cc5788bd736be92b3810d3fea398fadc8865b1;p=libs%2Fgl.git Fix bugs that crept in with refactoring Also add an additional safeguard against an infinite loop --- diff --git a/blender/io_mesh_mspgl/export_mspgl.py b/blender/io_mesh_mspgl/export_mspgl.py index c776c54f..c0fd96e9 100644 --- a/blender/io_mesh_mspgl/export_mspgl.py +++ b/blender/io_mesh_mspgl/export_mspgl.py @@ -111,8 +111,9 @@ class Exporter: island.append(face) for n in f.get_neighbors(): - n.flag = True - queue.append(n) + if not n.flag: + n.flag = True + queue.append(n) # Unflag the island for the next phase for f in island: @@ -127,7 +128,7 @@ class Exporter: if f.flag: continue - score = sum(n.flag for n in f.get_neighbors()) + score = sum(not n.flag for n in f.get_neighbors()) if score>0 and score