summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDarren Salt <devspam@moreofthesa.me.uk>2012-06-09 15:38:03 +0100
committerDarren Salt <devspam@moreofthesa.me.uk>2012-06-09 15:38:03 +0100
commit8eae9306239d6683d7cd06bf92be02bbd1c43865 (patch)
tree002ff64cc690e0470c3c83f83892f34ce773ba58
parent7d997a77166b94aea43afbbc252f1aa0af00a7fa (diff)
downloadxine-lib-8eae9306239d6683d7cd06bf92be02bbd1c43865.tar.gz
xine-lib-8eae9306239d6683d7cd06bf92be02bbd1c43865.tar.bz2
Fix a possible NULL dereference when cleaning up in the FFT vis plugin code.
-rw-r--r--ChangeLog1
-rw-r--r--src/post/visualizations/fft.c11
2 files changed, 8 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 16ba11b74..9e765ed92 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,6 @@
xine-lib (1.1.21) ????-??-??
* Fix a potential double-free (goom) when playing AAC files.
+ * Fix a possible clean-up crash in the goom FFT code.
* Fix matroska header compression.
* MPEG-TS fixes and enhancements
* Improved syncing of DVB subtitles
diff --git a/src/post/visualizations/fft.c b/src/post/visualizations/fft.c
index 7e32dbbf6..ac109e379 100644
--- a/src/post/visualizations/fft.c
+++ b/src/post/visualizations/fft.c
@@ -153,10 +153,13 @@ fft_t *fft_new (int bits)
void fft_dispose(fft_t *fft)
{
- free(fft->SineTable);
- free(fft->CosineTable);
- free(fft->WinTable);
- free(fft);
+ if (fft)
+ {
+ free(fft->SineTable);
+ free(fft->CosineTable);
+ free(fft->WinTable);
+ free(fft);
+ }
}
/*