From de5b9317ae9e91274411af7479ab92fcd1737981 Mon Sep 17 00:00:00 2001 From: Chris Hafey Date: Wed, 20 May 2020 19:09:15 +0000 Subject: [PATCH] changed ERROR->WARNING for log messages --- src/lib/openjp2/j2k.c | 3 +-- src/lib/openjp2/t2.c | 5 +---- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/src/lib/openjp2/j2k.c b/src/lib/openjp2/j2k.c index f9495ad8..bcecb4b1 100644 --- a/src/lib/openjp2/j2k.c +++ b/src/lib/openjp2/j2k.c @@ -4964,9 +4964,8 @@ static OPJ_BOOL opj_j2k_read_sod(opj_j2k_t *p_j2k, /* Check enough bytes left in stream before allocation */ if ((OPJ_OFF_T)p_j2k->m_specific_param.m_decoder.m_sot_length > opj_stream_get_number_byte_left(p_stream)) { - opj_event_msg(p_manager, EVT_ERROR, + opj_event_msg(p_manager, EVT_WARNING, "Tile part length size inconsistent with stream length\n"); - //return OPJ_FALSE; } if (p_j2k->m_specific_param.m_decoder.m_sot_length > UINT_MAX - OPJ_COMMON_CBLK_DATA_EXTRA) { diff --git a/src/lib/openjp2/t2.c b/src/lib/openjp2/t2.c index 23f6c9d0..b72c2e5a 100644 --- a/src/lib/openjp2/t2.c +++ b/src/lib/openjp2/t2.c @@ -1427,13 +1427,10 @@ static OPJ_BOOL opj_t2_read_packet_data(opj_t2_t* p_t2, (OPJ_SIZE_T)l_current_data) || (l_current_data + l_seg->newlen > p_src_data + p_max_length) || (partial_buffer)) { - opj_event_msg(p_manager, EVT_ERROR, + opj_event_msg(p_manager, EVT_WARNING, "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); - // NOTE - originall we would return OPJ_FALSE here when we encountered partial bitstream - //return OPJ_FALSE; - // skip this codeblock since it is a partial read partial_buffer = 1; l_cblk->numchunks = 0;