summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2020-07-29 22:29:45 +0200
committerCarl Hetherington <cth@carlh.net>2020-07-29 20:38:50 +0000
commit5351a0970c7951190b4e518967040ad3caed70d6 (patch)
tree2dd5864b47cbb68df9ebcb74232cb898e646d91e
parent525d5c76b24119125572805ef041b1b226233069 (diff)
Fix memory leak which also causes strange flickering in the audio
analysis window while the analysis is running. Cherry-picked from 6b1d9adcf6e75fc8e441b61108a2169bda6a6094 in v2.15.x.
-rw-r--r--src/wx/audio_plot.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/wx/audio_plot.cc b/src/wx/audio_plot.cc
index 079f69cdc..2c297a7a8 100644
--- a/src/wx/audio_plot.cc
+++ b/src/wx/audio_plot.cc
@@ -145,6 +145,7 @@ AudioPlot::paint ()
if (!_analysis || _analysis->channels() == 0) {
gc->SetFont (gc->CreateFont (*wxNORMAL_FONT));
gc->DrawText (_message, 32, 32);
+ delete gc;
return;
}