From 1d447dcd19120ed2fd14511589220438ce1904bc Mon Sep 17 00:00:00 2001 From: Howard Trickey Date: Thu, 10 Dec 2020 09:11:43 -0500 Subject: [PATCH] Fix T83630 Exact Boolean assert failure in Debug build. I thought I had reasoned that the add_patch would only happen when the patch was not already in a cell, but I missed reasoning about merged cells. So switched to a set 'add' instead of 'add_new'. --- source/blender/blenlib/intern/mesh_boolean.cc | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/source/blender/blenlib/intern/mesh_boolean.cc b/source/blender/blenlib/intern/mesh_boolean.cc index 2db939cd628..88d90a7816f 100644 --- a/source/blender/blenlib/intern/mesh_boolean.cc +++ b/source/blender/blenlib/intern/mesh_boolean.cc @@ -400,11 +400,6 @@ class Cell { Cell() = default; void add_patch(int p) - { - patches_.add_new(p); - } - - void add_patch_non_duplicates(int p) { patches_.add(p); } @@ -693,7 +688,7 @@ static void merge_cells(int merge_to, int merge_from, CellsInfo &cinfo, PatchesI merge_to_cell = cinfo.cell(final_merge_to); } for (int cell_p : merge_from_cell.patches()) { - merge_to_cell.add_patch_non_duplicates(cell_p); + merge_to_cell.add_patch(cell_p); Patch &patch = pinfo.patch(cell_p); if (patch.cell_above == merge_from) { patch.cell_above = merge_to;