From: Timo Heister Date: Tue, 28 Jul 2015 17:28:23 +0000 (-0400) Subject: early out compute_point_to_point_communication_pattern() X-Git-Tag: v8.4.0-rc2~706^2~2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d46ed19e24986ccbc211656f8650afe403c9431b;p=dealii.git early out compute_point_to_point_communication_pattern() Fixes another stl invalid access --- diff --git a/source/base/mpi.cc b/source/base/mpi.cc index cd69c9c358..28a575330f 100644 --- a/source/base/mpi.cc +++ b/source/base/mpi.cc @@ -141,6 +141,10 @@ namespace Utilities const unsigned int max_n_destinations = Utilities::MPI::max (destinations.size(), mpi_comm); + if (max_n_destinations==0) + // all processes have nothing to send/receive: + return std::vector(); + // now that we know the number // of data packets every // processor wants to send, set