Fix memory leak which also causes strange flickering in the audio
authorCarl Hetherington <cth@carlh.net>
Wed, 29 Jul 2020 20:29:45 +0000 (22:29 +0200)
committerCarl Hetherington <cth@carlh.net>
Wed, 29 Jul 2020 20:29:45 +0000 (22:29 +0200)
analysis window while the analysis is running.

src/wx/audio_plot.cc

index 629de77..b8b14b2 100644 (file)
@@ -150,6 +150,7 @@ AudioPlot::paint ()
        if (!_analysis || _analysis->channels() == 0) {
                gc->SetFont (gc->CreateFont (*wxNORMAL_FONT));
                gc->DrawText (_message, 32, 32);
+               delete gc;
                return;
        }