From: Wolfgang Bangerth Date: Sat, 13 Feb 2010 15:52:23 +0000 (+0000) Subject: Make things work correctly. X-Git-Tag: v8.0.0~6468 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3ce41b8167632e0c4a8572f32d318a3e6dffd2ab;p=dealii.git Make things work correctly. git-svn-id: https://svn.dealii.org/trunk@20593 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/deal.II/source/multigrid/mg_tools.cc b/deal.II/deal.II/source/multigrid/mg_tools.cc index c1ea3c7c70..805bc75597 100644 --- a/deal.II/deal.II/source/multigrid/mg_tools.cc +++ b/deal.II/deal.II/source/multigrid/mg_tools.cc @@ -1150,10 +1150,12 @@ MGTools::make_boundary_list( // field to store the indices std::vector face_dofs; face_dofs.reserve (DoFTools::max_dofs_per_face(dof)); - std::fill (face_dofs.begin (), face_dofs.end (), DoFHandler::invalid_dof_index); + std::fill (face_dofs.begin (), face_dofs.end (), + DoFHandler::invalid_dof_index); - typename MGDoFHandler::cell_iterator cell = dof.begin(), - endc = dof.end(); + typename MGDoFHandler::cell_iterator + cell = dof.begin(), + endc = dof.end(); for (; cell!=endc; ++cell) for (unsigned int face_no = 0; face_no < GeometryInfo::faces_per_cell; ++face_no) @@ -1306,12 +1308,16 @@ make_boundary_list(const MGDoFHandler& dof, std::vector& boundary_indices, const std::vector& component_mask) { + Assert (boundary_indices.size() == dof.get_tria().n_levels(), + ExcDimensionMismatch (boundary_indices.size(), + dof.get_tria().n_levels())); + std::vector > - my_boundary_indices (boundary_indices.size()); + my_boundary_indices (dof.get_tria().n_levels()); make_boundary_list (dof, function_map, my_boundary_indices, component_mask); - for (unsigned int i=0; i