]> git.sesse.net Git - ffmpeg/commitdiff
hevc_mvs: prevent unitialized use
authorVittorio Giovara <vittorio.giovara@gmail.com>
Sun, 9 Nov 2014 07:48:39 +0000 (08:48 +0100)
committerVittorio Giovara <vittorio.giovara@gmail.com>
Tue, 11 Nov 2014 10:49:47 +0000 (11:49 +0100)
CC: libav-stable@libav.org
Bug-Id: CID 1244202

libavcodec/hevc_mvs.c

index 721eb3af414044bb87cf7607e4db6c10c0c4ab4c..48cd234bd3651da5e2913fdef9a4a0b4db8e1c3c 100644 (file)
@@ -470,7 +470,7 @@ static void derive_spatial_merge_candidates(HEVCContext *s, int x0, int y0,
     // temporal motion vector candidate
     if (s->sh.slice_temporal_mvp_enabled_flag &&
         nb_merge_cand < s->sh.max_num_merge_cand) {
-        Mv mv_l0_col, mv_l1_col;
+        Mv mv_l0_col = { 0 }, mv_l1_col = { 0 };
         int available_l0 = temporal_luma_motion_vector(s, x0, y0, nPbW, nPbH,
                                                        0, &mv_l0_col, 0);
         int available_l1 = (s->sh.slice_type == B_SLICE) ?