[FFmpeg-devel] [PATCH] avcodec/hevc_ps: Always initialize backup in decode_vui()
Michael Niedermayer
michaelni at gmx.at
Sat Sep 6 12:40:34 CEST 2014
Fixes CID1237283
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
---
libavcodec/hevc_ps.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/libavcodec/hevc_ps.c b/libavcodec/hevc_ps.c
index 365652c..219af2f 100644
--- a/libavcodec/hevc_ps.c
+++ b/libavcodec/hevc_ps.c
@@ -526,9 +526,7 @@ static void decode_vui(HEVCContext *s, HEVCSPS *sps)
vui->frame_field_info_present_flag = get_bits1(gb);
vui->default_display_window_flag = get_bits1(gb);
- // Backup context in case an alternate header is detected
- if( get_bits_left(gb) >= 66)
- memcpy(&backup, gb, sizeof(backup));
+ memcpy(&backup, gb, sizeof(backup));
if (vui->default_display_window_flag) {
//TODO: * 2 is only valid for 420
--
1.7.9.5
More information about the ffmpeg-devel
mailing list