diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2023-12-08 16:47:20 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-12-08 16:47:20 +0100 |
| commit | 03afd06b45b5053ba802356151e878e7aa20dc71 (patch) | |
| tree | 80e0c7eb2f9fd0a056af23895ec8fa56f535ac1d /src/lib | |
| parent | 2c8c5025ce082df7bb751bc4f7552f3bb923964f (diff) | |
| parent | 478b20d9234d6f856cbb4a2a67ee858dc99293d5 (diff) | |
Merge pull request #1492 from headshog/fix-ht-dec
fix ht_dec.c:1215
Diffstat (limited to 'src/lib')
| -rw-r--r-- | src/lib/openjp2/ht_dec.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/lib/openjp2/ht_dec.c b/src/lib/openjp2/ht_dec.c index 120d7e49..9ea061f3 100644 --- a/src/lib/openjp2/ht_dec.c +++ b/src/lib/openjp2/ht_dec.c @@ -1210,6 +1210,9 @@ OPJ_BOOL opj_t1_ht_decode_cblk(opj_t1_t *t1, /* Concatenate all chunks */ cblkdata = t1->cblkdatabuffer; + if (cblkdata == NULL) { + return OPJ_FALSE; + } cblk_len = 0; for (i = 0; i < cblk->numchunks; i++) { memcpy(cblkdata + cblk_len, cblk->chunks[i].data, cblk->chunks[i].len); |
