Commit 36936080 authored by Sean McGovern's avatar Sean McGovern Committed by Ronald S. Bultje
Browse files

wmapro: prevent division by zero when sample rate is unspecified

This fixes Bugzilla #327:
Signed-off-by: default avatarRonald S. Bultje <>
parent 7191e1c4
......@@ -340,6 +340,11 @@ static av_cold int decode_init(AVCodecContext *avctx)
if (s->avctx->sample_rate <= 0) {
av_log(avctx, AV_LOG_ERROR, "invalid sample rate\n");
s->num_channels = avctx->channels;
if (s->num_channels < 0) {
Markdown is supported
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