]> https://gitweb.dealii.org/ - dealii.git/commit
Avoid a memory leak. 3519/head
authorWolfgang Bangerth <bangerth@colostate.edu>
Thu, 10 Nov 2016 16:15:18 +0000 (09:15 -0700)
committerWolfgang Bangerth <bangerth@colostate.edu>
Thu, 10 Nov 2016 16:15:18 +0000 (09:15 -0700)
commit8035a9d0982025b9ffe9042a44017e7a2b78a480
tree20ef3ae4c75973bb6d9b70e2cbef8272115d7033
parentfaef848d76b10ada07f28e98eeef8c0ea0e05d3c
Avoid a memory leak.

In fact, the test really tries very hard to create a memory leak, and
even verifies that it happens. But this then leads to downstream heartbreak
if you run a memory checker because you get pulled over for it.

Fix the issue by cleaning up the memory leak after we have verified that
the code that ran before really did leak the memory, by keeping a pointer
to the leaked object after all, and deleting it at the end of it all.
tests/serialization/pointer_02.cc
tests/serialization/pointer_02.output

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.