some notes on mem-leaks...

This commit is contained in:
Robin Gareus 2016-04-24 13:22:15 +02:00
parent e3536fbefe
commit f6a621346c
3 changed files with 7 additions and 1 deletions

View file

@ -582,6 +582,11 @@ PluginManager::ladspa_discover (string path)
DEBUG_TRACE (DEBUG::PluginManager, string_compose ("LADSPA plugin found at %1\n", path));
for (uint32_t i = 0; ; ++i) {
/* if a ladspa plugin allocates memory here
* it is never free()ed (or plugin-dependent only when unloading).
* For some plugins memory allocated is incremental, we should
* avoid re-scanning plugins and file bug reports.
*/
if ((descriptor = dfunc (i)) == 0) {
break;
}

View file

@ -284,6 +284,7 @@ TempoMap::TempoMap (framecnt_t fr)
start.beats = 1;
start.ticks = 0;
// these leak memory, well Metrics does
TempoSection *t = new TempoSection (start, _default_tempo.beats_per_minute(), _default_tempo.note_type());
MeterSection *m = new MeterSection (start, _default_meter.divisions_per_bar(), _default_meter.note_divisor());

View file

@ -444,7 +444,7 @@ AbstractUI<RequestObject>::call_slot (InvalidationRecord* invalidation, const bo
template<typename RequestObject> void*
AbstractUI<RequestObject>::request_buffer_factory (uint32_t num_requests)
{
RequestBuffer* mcr = new RequestBuffer (num_requests);
RequestBuffer* mcr = new RequestBuffer (num_requests); // leaks
per_thread_request_buffer.set (mcr);
return mcr;
}