From: Daniel Arndt Date: Sun, 9 Dec 2018 19:10:39 +0000 (+0100) Subject: Change structure of two Asserts X-Git-Tag: v9.1.0-rc1~500^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c14b9d538b3dda69c70dae84259c01dbbc4b5a47;p=dealii.git Change structure of two Asserts --- diff --git a/source/lac/scalapack.cc b/source/lac/scalapack.cc index 273abfc8b0..4e1e038ffc 100644 --- a/source/lac/scalapack.cc +++ b/source/lac/scalapack.cc @@ -2617,8 +2617,12 @@ ScaLAPACKMatrix::save( chunks_size_.first = n_rows; chunks_size_.second = 1; } - AssertIndexRange(chunks_size_.first - 1, n_rows); - AssertIndexRange(chunks_size_.second - 1, n_columns); + Assert(chunks_size_.first > 0, + ExcMessage("The row chunk size must be larger than 0.")); + AssertIndexRange(chunks_size_.first, n_rows + 1); + Assert(chunks_size_.second > 0, + ExcMessage("The column chunk size must be larger than 0.")); + AssertIndexRange(chunks_size_.second, n_columns + 1); # ifdef H5_HAVE_PARALLEL // implementation for configurations equipped with a parallel file system