summaryrefslogtreecommitdiff
path: root/apps/codecs/libmad/minimad.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/codecs/libmad/minimad.c')
-rw-r--r--apps/codecs/libmad/minimad.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/apps/codecs/libmad/minimad.c b/apps/codecs/libmad/minimad.c
index 6b443cf859..7a23b346c2 100644
--- a/apps/codecs/libmad/minimad.c
+++ b/apps/codecs/libmad/minimad.c
@@ -82,7 +82,7 @@ struct buffer {
82 82
83static 83static
84enum mad_flow input(void *data, 84enum mad_flow input(void *data,
85 struct mad_stream *stream) 85 struct mad_stream *stream)
86{ 86{
87 struct buffer *buffer = data; 87 struct buffer *buffer = data;
88 88
@@ -128,8 +128,8 @@ signed int scale(mad_fixed_t sample)
128 128
129static 129static
130enum mad_flow output(void *data, 130enum mad_flow output(void *data,
131 struct mad_header const *header, 131 struct mad_header const *header,
132 struct mad_pcm *pcm) 132 struct mad_pcm *pcm)
133{ 133{
134 unsigned int nchannels, nsamples; 134 unsigned int nchannels, nsamples;
135 mad_fixed_t const *left_ch, *right_ch; 135 mad_fixed_t const *left_ch, *right_ch;
@@ -169,14 +169,14 @@ enum mad_flow output(void *data,
169 169
170static 170static
171enum mad_flow error(void *data, 171enum mad_flow error(void *data,
172 struct mad_stream *stream, 172 struct mad_stream *stream,
173 struct mad_frame *frame) 173 struct mad_frame *frame)
174{ 174{
175 struct buffer *buffer = data; 175 struct buffer *buffer = data;
176 176
177 fprintf(stderr, "decoding error 0x%04x (%s) at byte offset %u\n", 177 fprintf(stderr, "decoding error 0x%04x (%s) at byte offset %u\n",
178 stream->error, mad_stream_errorstr(stream), 178 stream->error, mad_stream_errorstr(stream),
179 stream->this_frame - buffer->start); 179 stream->this_frame - buffer->start);
180 180
181 /* return MAD_FLOW_BREAK here to stop decoding (and propagate an error) */ 181 /* return MAD_FLOW_BREAK here to stop decoding (and propagate an error) */
182 182
@@ -207,8 +207,8 @@ int decode(unsigned char const *start, unsigned long length)
207 /* configure input, output, and error functions */ 207 /* configure input, output, and error functions */
208 208
209 mad_decoder_init(&decoder, &buffer, 209 mad_decoder_init(&decoder, &buffer,
210 input, 0 /* header */, 0 /* filter */, output, 210 input, 0 /* header */, 0 /* filter */, output,
211 error, 0 /* message */); 211 error, 0 /* message */);
212 212
213 /* start decoding */ 213 /* start decoding */
214 214