Commit 4297dbde authored by Alexandre Savard's avatar Alexandre Savard
Browse files

[#3116] Free speex preprocess memory in codec destructor

parent 0d2a642a
......@@ -107,6 +107,9 @@ class Speex : public AudioCodec
speex_bits_destroy (&_speex_enc_bits);
speex_encoder_destroy (_speex_enc_state);
_speex_enc_state = 0;
speex_preprocess_state_destroy( _preprocess_state);
_preprocess_state = NULL;
}
virtual int codecDecode (short *dst, unsigned char *src, unsigned int size) {
......
......@@ -106,6 +106,9 @@ class Speex : public AudioCodec
speex_bits_destroy (&_speex_enc_bits);
speex_encoder_destroy (_speex_enc_state);
_speex_enc_state = 0;
speex_preprocess_state_destroy( _preprocess_state);
_preprocess_state = NULL;
}
virtual int codecDecode (short *dst, unsigned char *src, unsigned int size) {
......
......@@ -105,6 +105,9 @@ class Speex : public AudioCodec
speex_bits_destroy (&_speex_enc_bits);
speex_encoder_destroy (_speex_enc_state);
_speex_enc_state = 0;
speex_preprocess_state_destroy( _preprocess_state);
_preprocess_state = NULL;
}
virtual int codecDecode (short *dst, unsigned char *src, unsigned int size) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment