aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2014-09-29 16:16:50 +0000
committerAnton Khirnov <anton@khirnov.net>2014-10-07 07:12:55 +0000
commit79a60c8e779242b5ba4c531b2c706c871e8e6420 (patch)
treeca475662733eb0289bc371fc4bf25e71dbc41cf1 /libavcodec
parent28816050e47b6dba430a52e429d21a864cffda8e (diff)
downloadffmpeg-79a60c8e779242b5ba4c531b2c706c871e8e6420.tar.gz
hevc_mvs: initialize the temporal MV in case of missing ref
The caller expects the MV to always be initialized.
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/hevc_mvs.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libavcodec/hevc_mvs.c b/libavcodec/hevc_mvs.c
index a611b762f1..8b172a268d 100644
--- a/libavcodec/hevc_mvs.c
+++ b/libavcodec/hevc_mvs.c
@@ -257,8 +257,10 @@ static int temporal_luma_motion_vector(HEVCContext *s, int x0, int y0,
HEVCFrame *ref = s->ref->collocated_ref;
- if (!ref)
+ if (!ref) {
+ memset(mvLXCol, 0, sizeof(*mvLXCol));
return 0;
+ }
tab_mvf = ref->tab_mvf;
colPic = ref->poc;