ext/mad/gstid3tag.c: reset v1 tag offset when there is no v1 tag. Fixes id3demux always consuming the last 128 bytes,...

Original commit message from CVS:
* 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.
This commit is contained in:
Benjamin Otte 2004-10-11 05:05:51 +00:00
parent 531b098203
commit 3560ecddcf
2 changed files with 13 additions and 4 deletions

View file

@ -1,3 +1,9 @@
2004-10-11 Benjamin Otte <otte@gnome.org>
* 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 <zaheerabbas at merali dot org>
* sys/v4l/gstv4lsrc.c: (gst_v4lsrc_palette_to_caps),

View file

@ -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;