Thanks, James.
"No naked news!" Now let's keep it that way. It is now easy to find all
occurrences of "new" in the program, which are mostly inside strings, and
review them.
I proposed changes to Roger to clean up the not-really memory leaks when
Nyquist shuts down, and I think he took them upstream, so we would get that
too with updated Nyquist libraries.
It's still possible to leak memory even with conscientious use of smart
pointers. One possible way is with a cycle of std::shared_ptr but I don't
think that exists anywhere.
Another more serious possibility is that some long persisting object keeps
pointers to memory longer than it needs. For instance, for each Effect
there is a singleton object. Keeping things in member variables of the
Effect, when they aren't needed outside of one effect computation, is a
memory leak of sorts, though not in the strict sense because there is
eventual reclamation when the program exits.
Even so, it is good to know that smart pointers are now used wherever there
is an allocation, or at least, so it is outside of lib-src.
PRL
Post by James CrookKudos to Paul for completing his work on new/delete in the most recent
commits.
Typical use of Audacity under the debugger now completes without any
memory leaks. The exception is Nyquist effects/generators, as Nyquist
does doesn't tidy up its mallocs on closing - but everything else I
tried does.
--James.
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel