Skip to content
Snippets Groups Projects
Commit c522b1b7 authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

add call to fftw_cleanup() before exiting to avoid bogus leak reports when compiling with FFTW v3.x

parent 8d384b91
No related branches found
No related tags found
No related merge requests found
......@@ -22,6 +22,10 @@
#include <fenv.h>
#endif
#ifdef FFT_FFTW3
#include <fftw3.h>
#endif
using namespace LAMMPS_NS;
/* ----------------------------------------------------------------------
......@@ -62,4 +66,10 @@ int main(int argc, char **argv)
#endif
MPI_Barrier(MPI_COMM_WORLD);
MPI_Finalize();
#ifdef FFT_FFTW3
// tell fftw3 to delete its global memory pool
// and thus avoid bogus valgrind memory leak reports
fftw_cleanup();
#endif
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment