ff_mqc_initdec(&t1->mqc, cblk->data, 0, 1);
while (passno--) {
+ if (bpno < 0) {
+ av_log(s->avctx, AV_LOG_ERROR, "bpno became negative\n");
+ return AVERROR_INVALIDDATA;
+ }
switch(pass_t) {
case 0:
decode_sigpass(t1, width, height, bpno + 1, bandpos,