diff --git a/ChangeLog b/ChangeLog index 9e96bee8f1..ee495d2f9e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2004-10-11 Benjamin Otte + + * ext/mad/gstid3tag.c: (gst_id3_tag_chain): + reset v1 tag offset when there is no v1 tag. Fixes id3demux always + consuming the last 128 bytes, even though it was valid mp3 data. + 2004-10-10 Zaheer Abbas Merali * sys/v4l/gstv4lsrc.c: (gst_v4lsrc_palette_to_caps), diff --git a/ext/mad/gstid3tag.c b/ext/mad/gstid3tag.c index ca0673d0ed..8bb100fb73 100644 --- a/ext/mad/gstid3tag.c +++ b/ext/mad/gstid3tag.c @@ -1082,11 +1082,14 @@ gst_id3_tag_chain (GstPad * pad, GstData * data) } else { GST_WARNING_OBJECT (tag, "detected ID3v1 tag, but couldn't parse it"); } - } else if (tag->v1tag_size != 0) { - GST_WARNING_OBJECT (tag, "bad non-ID3v1 tag at end of file"); } else { - GST_LOG_OBJECT (tag, "no ID3v1 tag (%" G_GUINT64_FORMAT ")", - GST_BUFFER_OFFSET (tag->buffer)); + if (tag->v1tag_size != 0) { + GST_WARNING_OBJECT (tag, "bad non-ID3v1 tag at end of file"); + } else { + GST_LOG_OBJECT (tag, "no ID3v1 tag (%" G_GUINT64_FORMAT ")", + GST_BUFFER_OFFSET (tag->buffer)); + tag->v1tag_offset = G_MAXUINT64; + } } gst_data_unref (GST_DATA (tag->buffer)); tag->buffer = NULL;