summaryrefslogtreecommitdiff
path: root/libavdevice/alsa-audio-dec.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavdevice/alsa-audio-dec.c')
-rw-r--r--libavdevice/alsa-audio-dec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavdevice/alsa-audio-dec.c b/libavdevice/alsa-audio-dec.c
index 4dac3f9cb4..833bca3b06 100644
--- a/libavdevice/alsa-audio-dec.c
+++ b/libavdevice/alsa-audio-dec.c
@@ -79,7 +79,7 @@ static av_cold int audio_read_header(AVFormatContext *s1,
return AVERROR(ENOMEM);
}
sample_rate = ap->sample_rate;
- codec_id = ap->audio_codec_id;
+ codec_id = s1->audio_codec_id;
ret = ff_alsa_open(s1, SND_PCM_STREAM_CAPTURE, &sample_rate, ap->channels,
&codec_id);