From 0996bbd27895874ce8b7738e839fb82e068a30fc Mon Sep 17 00:00:00 2001 From: Yoshihisa Uchida Date: Sat, 13 Mar 2010 05:53:54 +0000 Subject: corrects the smaf parser the following. - It is normally retrieved even if the position of wave data is not in given position from the head. - The problem that artist/title/composer cannot be given normally when the character code != iso8859-1, utf-8. - The problem that the position of chunk does not given correctly some mmf files. - artist/title/composer stored in not id3v1buf but id3v2buf. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25141 a1c6a512-1295-4272-9138-f99709370657 --- apps/codecs/libpcm/yamaha_adpcm.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'apps/codecs/libpcm') diff --git a/apps/codecs/libpcm/yamaha_adpcm.c b/apps/codecs/libpcm/yamaha_adpcm.c index 9f1a474..0b997ad 100644 --- a/apps/codecs/libpcm/yamaha_adpcm.c +++ b/apps/codecs/libpcm/yamaha_adpcm.c @@ -82,6 +82,12 @@ static bool set_format(struct pcm_format *format) { fmt = format; + if (fmt->channels == 0) + { + DEBUGF("CODEC_ERROR: channels is 0\n"); + return false; + } + if (fmt->bitspersample != 4) { DEBUGF("CODEC_ERROR: yamaha adpcm must be 4 bitspersample: %d\n", -- cgit v1.1