From 141cbc60b919c0e4e8c03963ce49402b3f9dbec8 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Sat, 14 Nov 2009 23:35:37 +0100 Subject: [PATCH] decoder/audio: eliminate the "bits" variable Pass the audiofile_setup_sample_format() result to audio_format_init_checked(). --- src/decoder/audiofile_plugin.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/decoder/audiofile_plugin.c b/src/decoder/audiofile_plugin.c index 4ef471f46..5a2096d00 100644 --- a/src/decoder/audiofile_plugin.c +++ b/src/decoder/audiofile_plugin.c @@ -127,7 +127,6 @@ audiofile_stream_decode(struct decoder *decoder, struct input_stream *is) AFvirtualfile *vf; int fs, frame_count; AFfilehandle af_fp; - int bits; struct audio_format audio_format; float total_time; uint16_t bit_rate; @@ -148,11 +147,9 @@ audiofile_stream_decode(struct decoder *decoder, struct input_stream *is) return; } - bits = audiofile_setup_sample_format(af_fp); - if (!audio_format_init_checked(&audio_format, afGetRate(af_fp, AF_DEFAULT_TRACK), - bits, + audiofile_setup_sample_format(af_fp), afGetVirtualChannels(af_fp, AF_DEFAULT_TRACK), &error)) { g_warning("%s", error->message);