mirror of
https://github.com/mollyim/webrtc.git
synced 2025-05-12 21:30:45 +01:00
Fix fuzzing issue for h265 bitstream parser
Bug: chromium:1513102 Change-Id: Ib78ecd349d4353f5729188ab2d16b9cf81043cad Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/333942 Reviewed-by: Philip Eliasson <philipel@webrtc.org> Reviewed-by: Erik Språng <sprang@webrtc.org> Commit-Queue: Erik Språng <sprang@webrtc.org> Reviewed-by: Sergey Silkin <ssilkin@webrtc.org> Cr-Commit-Position: refs/heads/main@{#41579}
This commit is contained in:
parent
0a7fc84887
commit
a9ef127f6f
1 changed files with 3 additions and 0 deletions
|
@ -12,6 +12,7 @@
|
|||
#include <stdlib.h>
|
||||
|
||||
#include <cstdint>
|
||||
#include <limits>
|
||||
#include <vector>
|
||||
|
||||
#include "common_video/h265/h265_common.h"
|
||||
|
@ -129,6 +130,8 @@ H265BitstreamParser::Result H265BitstreamParser::ParseNonParameterSetNalu(
|
|||
|
||||
uint32_t slice_segment_address_bits =
|
||||
H265::Log2Ceiling(pic_height_in_ctbs_y * pic_width_in_ctbs_y);
|
||||
TRUE_OR_RETURN(slice_segment_address_bits !=
|
||||
std::numeric_limits<uint32_t>::max());
|
||||
slice_reader.ConsumeBits(slice_segment_address_bits);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue