summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libavcodec/hevc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libavcodec/hevc.c b/libavcodec/hevc.c
index 859b2ab..bc89b17 100644
--- a/libavcodec/hevc.c
+++ b/libavcodec/hevc.c
@@ -779,6 +779,11 @@ static int hls_slice_header(HEVCContext *s)
sh->slice_ctb_addr_rs = sh->slice_segment_addr;
+ if (!s->sh.slice_ctb_addr_rs && s->sh.dependent_slice_segment_flag) {
+ av_log(s->avctx, AV_LOG_ERROR, "Impossible slice segment.\n");
+ return AVERROR_INVALIDDATA;
+ }
+
s->HEVClc.first_qp_group = !s->sh.dependent_slice_segment_flag;
if (!s->pps->cu_qp_delta_enabled_flag)
OpenPOWER on IntegriCloud