Skip to content
Snippets Groups Projects
Commit b9d71cdb authored by Paul B Mahol's avatar Paul B Mahol
Browse files

avcodec/mjpegbdec: use init_get_bits8()

parent 6a150fcd
No related branches found
No related tags found
No related merge requests found
......@@ -64,10 +64,8 @@ read_header:
s->restart_count = 0;
s->mjpb_skiptosod = 0;
if (buf_end - buf_ptr >= 1 << 28)
return AVERROR_INVALIDDATA;
init_get_bits(&hgb, buf_ptr, /*buf_size*/(buf_end - buf_ptr)*8);
if ((ret = init_get_bits8(&hgb, buf_ptr, /*buf_size*/(buf_end - buf_ptr))) < 0)
return ret;
skip_bits(&hgb, 32); /* reserved zeros */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment