]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Only access elements of a vector if it is not empty.
authorbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Fri, 1 Jul 2011 00:14:00 +0000 (00:14 +0000)
committerbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Fri, 1 Jul 2011 00:14:00 +0000 (00:14 +0000)
git-svn-id: https://svn.dealii.org/trunk@23896 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/source/dofs/dof_handler_policy.cc

index 8fafef684623750da4cb80ebd9aada6335a09a5b..16e916d3031d925e75c870d707fcde4c29ce63b3 100644 (file)
@@ -993,7 +993,8 @@ namespace internal
 
                                           // complete all sends, so that we can
                                           // safely destroy the buffers.
-         MPI_Waitall(requests.size(), &requests[0], MPI_STATUSES_IGNORE);
+         if (requests.size() > 0)
+           MPI_Waitall(requests.size(), &requests[0], MPI_STATUSES_IGNORE);
 
 
 #ifdef DEBUG

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.