summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian@centricular.com>2017-02-28 15:51:00 +0200
committerSebastian Dröge <sebastian@centricular.com>2017-02-28 15:51:00 +0200
commit6eef6bd1f5a52e500d484eded78d76943c941293 (patch)
treebc62efc683957d668bcf41b4b2887ec29d0d5f2c
parent9a62892428c9f22166b522fdbe7334409b528b85 (diff)
rawbaseparse: Assert that frame size is > 0
We would later divide by zero otherwise, and generally won't do the right thing. CID 1401383
-rw-r--r--gst/rawparse/gstrawbaseparse.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gst/rawparse/gstrawbaseparse.c b/gst/rawparse/gstrawbaseparse.c
index b41e4fa1c..2e7e70513 100644
--- a/gst/rawparse/gstrawbaseparse.c
+++ b/gst/rawparse/gstrawbaseparse.c
@@ -525,6 +525,7 @@ gst_raw_base_parse_handle_frame (GstBaseParse * parse,
frame_size =
klass->get_config_frame_size (raw_base_parse,
GST_RAW_BASE_PARSE_CONFIG_CURRENT);
+ g_assert (frame_size > 0);
in_size = gst_buffer_get_size (frame->buffer);