Audacity Bug Summary
••• Introduction •••
••• Keywords •••
    Audacity 3.0.3 development began 19th April 2021

Audacity Bugzilla



Bug 834 - Memory leak and orphan block files after cancelling generators
Memory leak and orphan block files after cancelling generators
Status: RESOLVED FIXED
Product: Audacity
Classification: Unclassified
Component: Application Core
2.0.7
Per OS All
: P5 Repeatable
Assigned To: Default Assignee for New Bugs
: patch_closed
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2015-01-18 03:01 UTC by Paul L
Modified: 2018-08-20 11:45 UTC (History)
6 users (show)

See Also:
Steps To Reproduce:
New project. Make a new track. Select the track and use any generator, such as white noise, specifying a long enough length that a progress dialog appears. Cancel the progress dialog. Save the project. Exit and restart Audacity. Reopen the project. Orphans! You can also prove a memory leak in a debugger if you put breakpoints at the starts of the two constructors of WaveTrack and the destructor of WaveTrack, and the end of QuitAudacity. Follow steps above, and at exit time, the number of calls to ~WaveTrack is less than the number of calls to the two constructors. SECOND PROCEDURE TO MAKE ORPHANS: New project. New track. Generate sound -- do not cancel. Select all, generate sound again -- this time, do cancel the progress dialog. Undo, so you see one, empty track again. Save. Close. Reopen. The cause of these orphans is different from the first case. The first patch is necessary but not sufficient to fix this.
Release Note:
First Git SHA:
Group: ---
Workaround:
Closed: 2018-08-20 00:00:00


Attachments
Fixes the orphans in bug 834, but not all of the memory leaks of tracks (1.32 KB, patch)
2015-01-18 03:37 UTC, Paul L
Details | Diff
Fixes other memory leaks in Bug 834, not the orphan file problem (1.87 KB, patch)
2015-01-18 03:52 UTC, Paul L
Details | Diff
A different fix for the second problem, one I like better. (1.63 KB, patch)
2015-01-18 05:14 UTC, Paul L
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Paul L 2015-01-18 03:01:31 UTC

    
Comment 1 Paul L 2015-01-18 03:37:56 UTC
Created attachment 552 [details]
Fixes the orphans in bug 834, but not all of the memory leaks of tracks
Comment 2 Paul L 2015-01-18 03:52:39 UTC
Created attachment 553 [details]
Fixes other memory leaks in Bug 834, not the orphan file problem
Comment 3 Paul L 2015-01-18 04:59:27 UTC
Correction, there is also a way to make orphans that is fixed by the second patch, but not fixed by the first.  See updated steps.
Comment 4 Paul L 2015-01-18 05:14:12 UTC
Created attachment 554 [details]
A different fix for the second problem, one I like better.
Comment 5 Steve Daulton 2015-01-18 12:07:12 UTC
Confirmed that the first steps to reproduce are repeatable on Linux.
Marked Repeatable, P5.
Comment 7 Peter Sampson 2017-11-08 06:51:38 UTC
I tested both sets of steps on W10 1nd macOS 10.3.1 High Sierra
Testing both on 2.2.0 and latest alphas.

All four use cases produce no orphans.

Accordingly I shall mark this long-fixed bug as RESOLVED