Test return value of opj_j2k_setup_decoding_tile() (commit ec31fa0c7f by ak-dxdy, #561)

This commit is contained in:
Even Rouault 2017-07-30 19:07:16 +02:00
parent ffa9a4f658
commit 22bf99ce02
1 changed files with 6 additions and 2 deletions

View File

@ -10636,7 +10636,9 @@ OPJ_BOOL opj_j2k_decode(opj_j2k_t * p_j2k,
opj_copy_image_header(p_image, p_j2k->m_output_image);
/* customization of the decoding */
opj_j2k_setup_decoding(p_j2k, p_manager);
if (!opj_j2k_setup_decoding(p_j2k, p_manager)) {
return OPJ_FALSE;
}
/* Decode the codestream */
if (! opj_j2k_exec(p_j2k, p_j2k->m_procedure_list, p_stream, p_manager)) {
@ -10746,7 +10748,9 @@ OPJ_BOOL opj_j2k_get_tile(opj_j2k_t *p_j2k,
p_j2k->m_specific_param.m_decoder.m_tile_ind_to_dec = (OPJ_INT32)tile_index;
/* customization of the decoding */
opj_j2k_setup_decoding_tile(p_j2k, p_manager);
if (!opj_j2k_setup_decoding(p_j2k, p_manager)) {
return OPJ_FALSE;
}
/* Decode the codestream */
if (! opj_j2k_exec(p_j2k, p_j2k->m_procedure_list, p_stream, p_manager)) {