]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Fix a silly bug I was sure I had fixed before... Hm.
authorwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Wed, 27 Oct 1999 13:16:01 +0000 (13:16 +0000)
committerwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Wed, 27 Oct 1999 13:16:01 +0000 (13:16 +0000)
git-svn-id: https://svn.dealii.org/trunk@1800 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/source/grid/intergrid_map.cc

index 9884daa8a8be9c5db66971c9a04ef1286447ac36..d3850351c39fd478971aefb7ffd93fd08f133c14 100644 (file)
@@ -135,9 +135,11 @@ InterGridMap<GridClass,dim>::set_entries_to_cell (const cell_iterator &src_cell,
   mapping[src_cell->level()][src_cell->index()] = dst_cell;
 
                                   // then do so for the children as well
-  for (unsigned int c=0; c<GeometryInfo<dim>::children_per_cell; ++c)
-    set_entries_to_cell (src_cell->child(c),
-                        dst_cell);
+                                  // if there are any
+  if (src_cell->has_children())
+    for (unsigned int c=0; c<GeometryInfo<dim>::children_per_cell; ++c)
+      set_entries_to_cell (src_cell->child(c),
+                          dst_cell);
 };
 
 

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.