From 98cf07565b3fe7cee98a5d6e1045e6cf4ac31ee4 Mon Sep 17 00:00:00 2001
From: Max Kahnt <max.kahnt@fu-berlin.de>
Date: Thu, 14 Jul 2016 15:36:21 +0200
Subject: [PATCH] Assert that ignoreNodes are set before dereferencing.

---
 dune/solvers/common/canignore.hh | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/dune/solvers/common/canignore.hh b/dune/solvers/common/canignore.hh
index 019e5f07..eb8b4a7f 100644
--- a/dune/solvers/common/canignore.hh
+++ b/dune/solvers/common/canignore.hh
@@ -3,6 +3,8 @@
 #ifndef DUNE_SOLVERS_COMMON_CANIGNORE_HH
 #define DUNE_SOLVERS_COMMON_CANIGNORE_HH
 
+#include <cassert>
+
 /** \brief Abstract base class for solvers and iterationsteps that are
  *      able to ignore degrees of freedom described by a bit field.
  */
@@ -59,6 +61,7 @@ public:
      */
     const BitVector& ignore() const
     {
+        assert(hasIgnore());
         return *ignoreNodes_;
     }
 
-- 
GitLab