]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Avoid use-after-scope when calling MappinQCache::initialize multiply
authorDaniel Arndt <arndtd@ornl.gov>
Fri, 5 Jun 2020 02:40:46 +0000 (22:40 -0400)
committerDaniel Arndt <arndtd@ornl.gov>
Fri, 5 Jun 2020 03:07:08 +0000 (23:07 -0400)
source/fe/mapping_q_cache.cc

index 8af4eb2b07b32dd635bdd829e0f79a27968ad1d1..96271efab4ab4181b88cd43cdf1c21ab01ca4506 100644 (file)
@@ -94,6 +94,7 @@ MappingQCache<dim, spacedim>::initialize(
     const typename Triangulation<dim, spacedim>::cell_iterator &)>
     &compute_points_on_cell)
 {
+  clear_signal.disconnect();
   clear_signal = triangulation.signals.any_change.connect(
     [&]() -> void { this->support_point_cache.reset(); });
 

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.