edith_codecs
Clone
https://git.tahinli.com/Tahinli/edith_codecs.git
0 watching0 forksRust370.3 MiB9b67700Tahinli3 days ago4021 commits
| 1 | //! Regression inputs found by the `parse_params_slice` fuzz target (`crates/ec-h265/fuzz`). |
| 2 | //! |
| 3 | //! The input is parsed the way the target parses it: every VPS, SPS and PPS, and each |
| 4 | //! slice header against the latest SPS and PPS. Each must come back without a panic |
| 5 | //! or an allocation the input did not justify. |
| 6 | |
| 7 | use SliceHeader; |
| 8 | use ; |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 | |
| 21 | |
| 22 | |
| 23 | |
| 24 | |
| 25 | |
| 26 | |
| 27 | |
| 28 | |
| 29 | |
| 30 | |
| 31 | |
| 32 | |
| 33 | |
| 34 | |
| 35 | |
| 36 | |
| 37 | |
| 38 | |
| 39 | /// A slice header whose `num_ref_idx_l0_active_minus1` comes from the PPS default |
| 40 | /// and is out of range: `pred_weight_table` sized a Vec from it (a 2.6 GB malloc). |
| 41 | |
| 42 | |
| 43 | |
| 44 | |
| 45 | |
| 46 | /// Long-term reference pictures whose `delta_poc_msb_cycle_lt` deltas accumulate past |
| 47 | /// `u32::MAX` (7-52): the running sum overflowed in `SliceHeader::parse`. |
| 48 | |
| 49 | |
| 50 | |
| 51 | |
| 52 | |
| 53 | /// A short-term reference picture set whose `delta_poc_s0_minus1` is far past its |
| 54 | /// 2^15 - 1 range: the running POC sum overflowed (`attempt to subtract with overflow`). |
| 55 | |
| 56 | |
| 57 | |
| 58 | |
| 59 | |
| 60 | /// An inter-predicted short-term RPS whose `abs_delta_rps_minus1` is out of range: |
| 61 | /// `delta_rps` and the POC sums built from it overflowed `i32`. |
| 62 | |
| 63 | |
| 64 | |
| 65 | |
| 66 | |
| 67 | /// A pred_weight_table whose chroma log2 weight denominator is the luma one plus a |
| 68 | /// near-`i32::MAX` delta: the sum overflowed. |
| 69 | |
| 70 | |
| 71 | |
| 72 | |
| 73 | |
| 74 | /// A slice header whose long-term picture counts sum past `u32::MAX`: the loop bound |
| 75 | /// `num_long_term_sps + num_long_term_pics` overflowed. |
| 76 | |
| 77 | |
| 78 | |
| 79 | |
| 80 | |
| 81 | /// A slice header whose entry point offset is read as the all-ones 32-bit value: the |
| 82 | /// `+ 1` that makes it a length overflowed. |
| 83 | |
| 84 | |
| 85 | |
| 86 |