diff options
| author | Eric Harvey <71228603+Eharve14@users.noreply.github.com> | 2022-01-18 15:55:10 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-01-18 21:55:10 +0100 |
| commit | 241e9e8efeb6750ef4202a61b3a436628e4f6d23 (patch) | |
| tree | 9a38bc9eb12cc5aa485f0ecec940c9fff3e7d341 /src/lib/openjp2/j2k.c | |
| parent | d87fd9279a9e0f8ce8fb23ab10e536410a907336 (diff) | |
Fix potential overflow related issues spotted by LGTM code analysis (#1402)
Diffstat (limited to 'src/lib/openjp2/j2k.c')
| -rw-r--r-- | src/lib/openjp2/j2k.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/openjp2/j2k.c b/src/lib/openjp2/j2k.c index e1901a31..220f4b1e 100644 --- a/src/lib/openjp2/j2k.c +++ b/src/lib/openjp2/j2k.c @@ -1677,7 +1677,7 @@ static OPJ_BOOL opj_j2k_check_poc_val(const opj_poc_t *p_pocs, assert(p_nb_pocs > 0); - packet_array = (OPJ_UINT32*) opj_calloc(step_l * p_num_layers, + packet_array = (OPJ_UINT32*) opj_calloc((size_t)step_l * p_num_layers, sizeof(OPJ_UINT32)); if (packet_array == 00) { opj_event_msg(p_manager, EVT_ERROR, |
