Commit 4853f6e7 authored by Martin Steghöfer's avatar Martin Steghöfer Committed by Thomas Daede

Fix ogg123 speex playback: Initialize channel matrix

The speex decoder didn't initialize the channel matrix,
which caused libao to print the cryptic error message
'" in channel matrix ""' and occasionally (depending on
the output device) to abort audio output.

Bug-Debian: https://bugs.debian.org/772766
parent f594ac04
......@@ -560,7 +560,19 @@ int read_speex_header (decoder_t *decoder)
if (!priv->frames_per_packet)
priv->frames_per_packet=1;
switch(decoder->actual_fmt.channels) {
case 1:
decoder->actual_fmt.matrix="M";
break;
case 2:
decoder->actual_fmt.matrix="L,R";
break;
default:
decoder->actual_fmt.matrix=NULL;
break;
}
priv->output = calloc(priv->frame_size *
decoder->actual_fmt.channels *
......
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