From: Martin Kronbichler Date: Mon, 25 Jul 2016 14:12:00 +0000 (+0200) Subject: Fix problem detected by address sanitizer X-Git-Tag: v8.5.0-rc1~850^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F2860%2Fhead;p=dealii.git Fix problem detected by address sanitizer --- diff --git a/include/deal.II/base/aligned_vector.h b/include/deal.II/base/aligned_vector.h index 7040bace72..cec47169f6 100644 --- a/include/deal.II/base/aligned_vector.h +++ b/include/deal.II/base/aligned_vector.h @@ -348,6 +348,9 @@ namespace internal virtual void apply_to_subrange (const std::size_t begin, const std::size_t end) const { + if (end == begin) + return; + // for classes trivial assignment can use memcpy. cast element to // (void*) to silence compiler warning for virtual classes (they will // never arrive here because they are non-trivial).