Update t2.c
This commit is contained in:
parent
4f36758ba6
commit
64fa86061c
|
@ -1349,15 +1349,15 @@ static OPJ_BOOL opj_t2_read_packet_data(opj_t2_t* p_t2,
|
|||
|
||||
do {
|
||||
/* Check possible overflow (on l_current_data only, assumes input args already checked) then size */
|
||||
if ((((OPJ_SIZE_T)l_current_data + (OPJ_SIZE_T)l_seg->newlen) <
|
||||
(OPJ_SIZE_T)l_current_data) ||
|
||||
(l_current_data + l_seg->newlen > p_src_data + p_max_length)) {
|
||||
opj_event_msg(p_manager, EVT_ERROR,
|
||||
"read: segment too long (%d) with max (%d) for codeblock %d (p=%d, b=%d, r=%d, c=%d)\n",
|
||||
l_seg->newlen, p_max_length, cblkno, p_pi->precno, bandno, p_pi->resno,
|
||||
p_pi->compno);
|
||||
return OPJ_FALSE;
|
||||
}
|
||||
//if ((((OPJ_SIZE_T)l_current_data + (OPJ_SIZE_T)l_seg->newlen) <
|
||||
// (OPJ_SIZE_T)l_current_data) ||
|
||||
// (l_current_data + l_seg->newlen > p_src_data + p_max_length)) {
|
||||
// opj_event_msg(p_manager, EVT_ERROR,
|
||||
// "read: segment too long (%d) with max (%d) for codeblock %d (p=%d, b=%d, r=%d, c=%d)\n",
|
||||
// l_seg->newlen, p_max_length, cblkno, p_pi->precno, bandno, p_pi->resno,
|
||||
// p_pi->compno);
|
||||
// return OPJ_FALSE;
|
||||
//}
|
||||
|
||||
#ifdef USE_JPWL
|
||||
/* we need here a j2k handle to verify if making a check to
|
||||
|
|
Loading…
Reference in New Issue