summaryrefslogtreecommitdiff
path: root/gst
diff options
context:
space:
mode:
authorMatej Knopp <matej.knopp@gmail.com>2011-12-01 15:49:40 +0100
committerVincent Penquerc'h <vincent.penquerch@collabora.co.uk>2012-01-24 14:09:48 +0000
commitb780639b2cc6dd9e61f18eadb9f0967aa2f1c3da (patch)
tree9cdf1542d28e81e6ab34f8db7c7725ddfb71f532 /gst
parent20cdee6aa6084d67ff7ad20dfbcd0c12a7d1a005 (diff)
Don't crash on empty laces
https://bugzilla.gnome.org/show_bug.cgi?id=665224
Diffstat (limited to 'gst')
-rw-r--r--gst/matroska/matroska-demux.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gst/matroska/matroska-demux.c b/gst/matroska/matroska-demux.c
index 1eed1603d..daace80e8 100644
--- a/gst/matroska/matroska-demux.c
+++ b/gst/matroska/matroska-demux.c
@@ -2903,6 +2903,11 @@ gst_matroska_demux_check_subtitle_buffer (GstElement * element,
data = gst_buffer_map (*buf, &size, NULL, GST_MAP_READ);
+ if (!data) {
+ gst_buffer_unmap (*buf, data, -1);
+ return GST_FLOW_OK;
+ }
+
if (!sub_stream->invalid_utf8) {
if (g_utf8_validate (data, size, NULL)) {
goto next;