I have been working in Fedora on a C++ client for the BaseX XML database. The original version of the client was developed in Eclipse and consisted of a test program and some source files that allowed communication with the database. The Eclipse version of the code gives no error messages when executed.
For the next version of the program, I used the files used for communication to develop a shared library. All I had to do for this was to add a public header.
The shared library can now be installed locally.
The command D_LIBRARY_PATH=~/lib/lib64 ./libTest
gives the same result as the original version but ends up with
double free or corruption (out)
Aborted (core dumped)
Valgrind cannot be used to inspect a library. And I also get no message about the location of the coredump.
How can I fix memory problems in a library?