gst/qtdemux/qtdemux.c: Use GST_WARNING instead of GST_ERROR for all the too short/long atoms when parsing.

Original commit message from CVS:
* gst/qtdemux/qtdemux.c: (qtdemux_parse), (qtdemux_parse_trak):
Use GST_WARNING instead of GST_ERROR for all the too short/long atoms
when parsing.
Also let's be a bit less vulgar in our warning messages :)
This commit is contained in:
Edward Hervey 2006-03-03 11:07:41 +00:00
parent eeef238248
commit 6be283efae

View file

@ -1064,7 +1064,7 @@ gst_qtdemux_chain (GstPad * sinkpad, GstBuffer * inbuf)
} }
if (stream == NULL) { if (stream == NULL) {
GST_WARNING_OBJECT (demux, "WHAT THE FUCK ?"); GST_WARNING_OBJECT (demux, "No stream found.");
ret = GST_FLOW_ERROR; ret = GST_FLOW_ERROR;
break; break;
} }
@ -1562,11 +1562,11 @@ qtdemux_parse (GstQTDemux * qtdemux, GNode * node, void *buffer, int length)
} }
len = QTDEMUX_GUINT32_GET (buf); len = QTDEMUX_GUINT32_GET (buf);
if (len < 8) { if (len < 8) {
GST_ERROR ("atom length too short (%d < 8)", len); GST_WARNING ("atom length too short (%d < 8)", len);
break; break;
} }
if (len > (end - buf)) { if (len > (end - buf)) {
GST_ERROR ("atom length too long (%d > %d)", len, end - buf); GST_WARNING ("atom length too long (%d > %d)", len, end - buf);
break; break;
} }
@ -1594,11 +1594,11 @@ qtdemux_parse (GstQTDemux * qtdemux, GNode * node, void *buffer, int length)
} }
len = QTDEMUX_GUINT32_GET (buf); len = QTDEMUX_GUINT32_GET (buf);
if (len < 8) { if (len < 8) {
GST_ERROR ("length too short (%d < 8)"); GST_WARNING ("length too short (%d < 8)");
break; break;
} }
if (len > (end - buf)) { if (len > (end - buf)) {
GST_ERROR ("length too long (%d > %d)", len, end - buf); GST_WARNING ("length too long (%d > %d)", len, end - buf);
break; break;
} }
@ -1627,11 +1627,11 @@ qtdemux_parse (GstQTDemux * qtdemux, GNode * node, void *buffer, int length)
} }
len = QTDEMUX_GUINT32_GET (buf); len = QTDEMUX_GUINT32_GET (buf);
if (len < 8) { if (len < 8) {
GST_ERROR ("length too short (%d < 8)"); GST_WARNING ("length too short (%d < 8)");
break; break;
} }
if (len > (end - buf)) { if (len > (end - buf)) {
GST_ERROR ("length too long (%d > %d)", len, end - buf); GST_WARNING ("length too long (%d > %d)", len, end - buf);
break; break;
} }
@ -1680,11 +1680,11 @@ qtdemux_parse (GstQTDemux * qtdemux, GNode * node, void *buffer, int length)
if (len == 0) if (len == 0)
break; break;
if (len < 8) { if (len < 8) {
GST_ERROR ("length too short (%d < 8)"); GST_WARNING ("length too short (%d < 8)");
break; break;
} }
if (len > (end - buf)) { if (len > (end - buf)) {
GST_ERROR ("length too long (%d > %d)", len, end - buf); GST_WARNING ("length too long (%d > %d)", len, end - buf);
break; break;
} }
@ -1710,11 +1710,11 @@ qtdemux_parse (GstQTDemux * qtdemux, GNode * node, void *buffer, int length)
} }
len = QTDEMUX_GUINT32_GET (buf); len = QTDEMUX_GUINT32_GET (buf);
if (len < 8) { if (len < 8) {
GST_ERROR ("length too short (%d < 8)"); GST_WARNING ("length too short (%d < 8)");
break; break;
} }
if (len > (end - buf)) { if (len > (end - buf)) {
GST_ERROR ("length too long (%d > %d)", len, end - buf); GST_WARNING ("length too long (%d > %d)", len, end - buf);
break; break;
} }
@ -1759,11 +1759,11 @@ qtdemux_parse (GstQTDemux * qtdemux, GNode * node, void *buffer, int length)
if (len == 0) if (len == 0)
break; break;
if (len < 8) { if (len < 8) {
GST_ERROR ("length too short (%d < 8)"); GST_WARNING ("length too short (%d < 8)");
break; break;
} }
if (len > (end - buf)) { if (len > (end - buf)) {
GST_ERROR ("length too long (%d > %d)", len, end - buf); GST_WARNING ("length too long (%d > %d)", len, end - buf);
break; break;
} }
@ -2591,7 +2591,7 @@ qtdemux_parse_trak (GstQTDemux * qtdemux, GNode * trak)
stream->compression = 320; stream->compression = 320;
} }
} else { } else {
GST_ERROR ("unknown version %08x", version); GST_WARNING ("unknown version %08x", version);
} }
stream->caps = qtdemux_audio_caps (qtdemux, stream, fourcc, NULL, 0, stream->caps = qtdemux_audio_caps (qtdemux, stream, fourcc, NULL, 0,