asfdemux: Don't unmap a buffer that doesn't exist

This commit is contained in:
Edward Hervey 2011-10-11 18:03:01 +02:00
parent 6b709f4656
commit 82a8cc6807

View file

@ -1149,11 +1149,13 @@ wrong_type:
("This doesn't seem to be an ASF file"));
return FALSE;
}
no_streams:
read_failed:
parse_failed:
{
gst_buffer_unmap (buf, data, data_size);
if (buf)
gst_buffer_unmap (buf, data, data_size);
gst_buffer_replace (&buf, NULL);
GST_ELEMENT_ERROR (demux, STREAM, DEMUX, (NULL), (NULL));
return FALSE;