From: Martin Kronbichler Date: Thu, 1 Jun 2017 13:11:17 +0000 (+0200) Subject: Also clear triangulation signals on destruction X-Git-Tag: v9.0.0-rc1~1548^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=db63347ee60c87d04305a9da98cc828586443526;p=dealii.git Also clear triangulation signals on destruction --- diff --git a/include/deal.II/grid/tria.h b/include/deal.II/grid/tria.h index 5ebac078a9..bbda49e643 100644 --- a/include/deal.II/grid/tria.h +++ b/include/deal.II/grid/tria.h @@ -2120,9 +2120,10 @@ public: /** * This signal is triggered whenever the Triangulation::clear() function - * is called. This signal is also triggered when loading a triangulation - * from an archive via Triangulation::load() as the previous content of - * the triangulation is first destroyed. + * is called and in the destructor of the triangulation. This signal is + * also triggered when loading a triangulation from an archive via + * Triangulation::load() as the previous content of the triangulation is + * first destroyed. * * The signal is triggered before the data structures of the * triangulation are destroyed. In other words, the functions diff --git a/source/grid/tria.cc b/source/grid/tria.cc index 1c86b45541..24f9ac015a 100644 --- a/source/grid/tria.cc +++ b/source/grid/tria.cc @@ -9039,6 +9039,9 @@ Triangulation::operator= (Triangulation &&tria) template Triangulation::~Triangulation () { + // notify listeners that the triangulation is going down... + signals.clear(); + levels.clear (); // the vertex_to_boundary_id_map_1d field should be unused except in