summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJames Courtier-Dutton <jcdutton@users.sourceforge.net>2003-08-31 16:37:32 +0000
committerJames Courtier-Dutton <jcdutton@users.sourceforge.net>2003-08-31 16:37:32 +0000
commit40a66ac25ad62bda86922c546ea4dfb854ba9df9 (patch)
tree9064533916d5eb1814c5c22ea231a3fd38e9eba7 /src
parentf70e18b8a6ebc1d27faea82801a659b26150ed45 (diff)
downloadxine-lib-40a66ac25ad62bda86922c546ea4dfb854ba9df9.tar.gz
xine-lib-40a66ac25ad62bda86922c546ea4dfb854ba9df9.tar.bz2
Fix .mp3 content detection for .mp3 files with a header or ID3.
Info from www.id3.org CVS patchset: 5320 CVS date: 2003/08/31 16:37:32
Diffstat (limited to 'src')
-rw-r--r--src/demuxers/demux_mpgaudio.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/demuxers/demux_mpgaudio.c b/src/demuxers/demux_mpgaudio.c
index d64334972..3987c68a1 100644
--- a/src/demuxers/demux_mpgaudio.c
+++ b/src/demuxers/demux_mpgaudio.c
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: demux_mpgaudio.c,v 1.106 2003/08/25 21:51:38 f1rmb Exp $
+ * $Id: demux_mpgaudio.c,v 1.107 2003/08/31 16:37:32 jcdutton Exp $
*
* demultiplexer for mpeg audio (i.e. mp3) streams
*
@@ -57,6 +57,7 @@
#define RIFF_TAG FOURCC_TAG('R', 'I', 'F', 'F')
#define AVI_TAG FOURCC_TAG('A', 'V', 'I', ' ')
#define CDXA_TAG FOURCC_TAG('C', 'D', 'X', 'A')
+#define ID3_TAG FOURCC_TAG('I', 'D', '3', 3)
typedef struct {
@@ -107,6 +108,8 @@ static int frequencies[2][3] = {
static int mpg123_head_check(unsigned long head) {
+ if (head == ID3_TAG)
+ return 1;
if ((head & 0xffe00000) != 0xffe00000)
return 0;
if (!((head >> 17) & 3))