summaryrefslogtreecommitdiff
path: root/libavcodec/nellymoserenc.c
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2012-04-08 20:25:08 +0200
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2012-04-08 20:26:25 +0200
commit03ef5047d15904ed34976c6ba11c9176529ee9e7 (patch)
tree7e5a3b4e48e2fc1fc96564f5a2065b311f2eaa0d /libavcodec/nellymoserenc.c
parenta7b1420ca27425b6e424c02d618045c834da61c9 (diff)
Fix nellymoser encoder crash with hardcoded tables.
Use the correct init function to avoid crashes due to writing to a rodata location. Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Diffstat (limited to 'libavcodec/nellymoserenc.c')
-rw-r--r--libavcodec/nellymoserenc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/nellymoserenc.c b/libavcodec/nellymoserenc.c
index 29b5049a7f..b40e70866b 100644
--- a/libavcodec/nellymoserenc.c
+++ b/libavcodec/nellymoserenc.c
@@ -174,7 +174,7 @@ static av_cold int encode_init(AVCodecContext *avctx)
ff_dsputil_init(&s->dsp, avctx);
/* Generate overlap window */
- ff_sine_window_init(ff_sine_128, 128);
+ ff_init_ff_sine_windows(7);
for (i = 0; i < POW_TABLE_SIZE; i++)
pow_table[i] = -pow(2, -i / 2048.0 - 3.0 + POW_TABLE_OFFSET);