]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Add a guard for the non-MPI case 3104/head
authorDaniel Arndt <d.arndt@math.uni-goettingen.de>
Mon, 12 Sep 2016 21:01:17 +0000 (23:01 +0200)
committerDaniel Arndt <d.arndt@math.uni-goettingen.de>
Mon, 12 Sep 2016 21:01:17 +0000 (23:01 +0200)
source/base/index_set.cc

index b174c0a33c2d0329d35ac1a9672ee4f8e85515b9..bff0e5349f8d1db6d1442e262d404b3dae405eb2 100644 (file)
@@ -560,6 +560,7 @@ IndexSet::is_ascending_and_one_to_one (const MPI_Comm &communicator) const
   if (n_global_elements != size())
     return false;
 
+#ifdef DEAL_II_WITH_MPI
   // Non-contiguous IndexSets can't be linear.
   const bool all_contiguous = (Utilities::MPI::min (is_contiguous() ? 1 : 0, communicator) == 1);
   if (!all_contiguous)
@@ -606,6 +607,9 @@ IndexSet::is_ascending_and_one_to_one (const MPI_Comm &communicator) const
   MPI_Bcast(&is_ascending, 1, MPI_INT, 0, communicator);
 
   return (is_ascending==1);
+#else
+  return true;
+#endif //DEAL_II_WITH_MPI
 }
 
 

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.