From f6b255ca85820e428e39ad7ce1798354cb0fc168 Mon Sep 17 00:00:00 2001 From: heister Date: Sun, 21 Jul 2013 23:47:29 +0000 Subject: [PATCH] revert to iterating back-wards which was changed in r30061 and broke a couple of tests (I don't understand why exactly though) git-svn-id: https://svn.dealii.org/trunk@30082 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/source/grid/tria.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/deal.II/source/grid/tria.cc b/deal.II/source/grid/tria.cc index 42aaa7279e..d55a04bedf 100644 --- a/deal.II/source/grid/tria.cc +++ b/deal.II/source/grid/tria.cc @@ -12208,9 +12208,9 @@ void Triangulation::execute_coarsening () // // since we delete the *children* of cells, we only need to start // considering cells on the second highest level, n_levels()-2. - for (int level = n_levels()-2; level>=0; --level) - for (cell = begin(level); cell!=end(level); ++cell) - if (cell->user_flag_set()) + if (levels.size() >= 2) + for (cell = last(); cell!=endc; --cell) + if (cell->user_flag_set() && cell->level()<=static_cast(levels.size()-2)) // use a separate function, // since this is dimension // specific -- 2.39.5