diff --git a/indra/libopenjpeg/tcd.c b/indra/libopenjpeg/tcd.c index 8f2f24329..d29a0157b 100644 --- a/indra/libopenjpeg/tcd.c +++ b/indra/libopenjpeg/tcd.c @@ -1403,6 +1403,11 @@ bool tcd_decode_tile(opj_tcd_t *tcd, unsigned char *src, int len, int tileno, op } } + if(!tilec->data) { + opj_event_msg(tcd->cinfo, EVT_ERROR, "Error decoding tile. null data\n"); + return false; + } + numres2decode = tcd->image->comps[compno].resno_decoded + 1; if(numres2decode > 0){ if (tcd->tcp->tccps[compno].qmfbid == 1) {