From: David Wells Date: Mon, 13 May 2019 14:58:16 +0000 (-0400) Subject: cppcheck: add an assertion. X-Git-Tag: v9.1.0-rc1~18^2~5 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=75a723f2b5f678bf69210ac49a31d804617b963c;p=dealii.git cppcheck: add an assertion. --- diff --git a/source/lac/sparsity_tools.cc b/source/lac/sparsity_tools.cc index b62a712c26..4d612ab1e4 100644 --- a/source/lac/sparsity_tools.cc +++ b/source/lac/sparsity_tools.cc @@ -388,6 +388,7 @@ namespace SparsityTools std::fill(partition_indices.begin(), partition_indices.end(), 0); // copy from export_to_part to partition_indices, whose part_ids != 0. + Assert(export_to_part != nullptr, ExcInternalError()); for (int i = 0; i < num_export; i++) partition_indices[export_local_ids[i]] = export_to_part[i]; #endif