summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAllen Zhang <Zhang, Zhangfei>2016-07-21 11:24:31 +0300
committerSreerenj Balachandran <sreerenj.balachandran@intel.com>2016-07-21 11:36:32 +0300
commit9701bb18eebd586f1cce43be3e4de7e103f5b88a (patch)
tree361685becddbe66722afb32208efe2879c77f996
parenta7df4ced871f4f5865e2f51ce334de684322d939 (diff)
decoder: h265: handle the SEI NAL units included in codec_data
The prefix/suffix SEI nal units can appear in codec_data too which weren't handled before. Parse these SEI headers to fix the segfault. https://bugzilla.gnome.org/show_bug.cgi?id=768544
-rw-r--r--gst-libs/gst/vaapi/gstvaapidecoder_h265.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/gst-libs/gst/vaapi/gstvaapidecoder_h265.c b/gst-libs/gst/vaapi/gstvaapidecoder_h265.c
index ef703d02..d44047c7 100644
--- a/gst-libs/gst/vaapi/gstvaapidecoder_h265.c
+++ b/gst-libs/gst/vaapi/gstvaapidecoder_h265.c
@@ -2696,6 +2696,16 @@ gst_vaapi_decoder_h265_decode_codec_data (GstVaapiDecoder *
if (status != GST_VAAPI_DECODER_STATUS_SUCCESS)
goto cleanup;
break;
+ case GST_H265_NAL_SUFFIX_SEI:
+ case GST_H265_NAL_PREFIX_SEI:
+ status = parse_sei (decoder, &unit);
+ if (status != GST_VAAPI_DECODER_STATUS_SUCCESS)
+ goto cleanup;
+ status = decode_sei (decoder, &unit);
+ if (status != GST_VAAPI_DECODER_STATUS_SUCCESS)
+ goto cleanup;
+ break;
+
}
ofs = pi->nalu.offset + pi->nalu.size;
gst_vaapi_parser_info_h265_replace (&pi, NULL);