Module: libav
Branch: release/0.8
Commit: 7fe9c66bf577b2c1dc6fe74a81b7117d55d98fa6

Author:    Diego Biurrun <[email protected]>
Committer: Diego Biurrun <[email protected]>
Date:      Mon Jan  9 17:22:08 2017 +0100

h264: Use the right H264Context for struct member comparison

Fixes crashes with slice threading.

---

 libavcodec/h264.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index 2f54508..ea6845a 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -2796,8 +2796,8 @@ static int decode_slice_header(H264Context *h, 
H264Context *h0){
     if (s->context_initialized
         && (   s->width != s->avctx->width || s->height != s->avctx->height
             || av_cmp_q(h->sps.sar, s->avctx->sample_aspect_ratio) ||
-            h->chroma_format_idc != h->sps.chroma_format_idc ||
-            h->bit_depth         != h->sps.bit_depth_luma)) {
+            h0->chroma_format_idc != h->sps.chroma_format_idc ||
+            h0->bit_depth         != h->sps.bit_depth_luma)) {
         if(h != h0 || (HAVE_THREADS && h->s.avctx->active_thread_type & 
FF_THREAD_FRAME)) {
             av_log_missing_feature(s->avctx, "Width/height changing with 
threads is", 0);
             return AVERROR_PATCHWELCOME;   // width / height changed during 
parallelized decoding

_______________________________________________
libav-commits mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-commits

Reply via email to