Fixes: CID1500300 Unchecked return value
Unified · Split
| @@ -243,7 +243,9 @@ static int decode_blocks(AVCodecContext *avctx, AVFrame *p, · 242 unmodified lines | ||
| 243 | 243 | |
| 244 | 244 | bytestream2_seek(&dgb, s->y_data_offset + row_offset, SEEK_SET); |
| 245 | 245 | |
| 246 | − init_get_bits8(&bit, dgb.buffer, bytestream2_get_bytes_left(&dgb)); | |
| 246 | + ret = init_get_bits8(&bit, dgb.buffer, bytestream2_get_bytes_left(&dgb)); | |
| 247 | + if (ret < 0) | |
| 248 | + return ret; | |
| 247 | 249 | for (int x = 0; x < avctx->width; x += 4) { |
| 248 | 250 | unsigned item = bytestream2_get_le32(gb); |
| 249 | 251 | unsigned y_min = item & 4095; |