Fix invalid read in pngtoimage
This commit is contained in:
parent
348e96e44b
commit
c0abb808f5
|
@ -3320,7 +3320,9 @@ opj_image_t *pngtoimage(const char *read_idf, opj_cparameters_t * params)
|
||||||
r = image->comps[0].data;
|
r = image->comps[0].data;
|
||||||
g = image->comps[1].data;
|
g = image->comps[1].data;
|
||||||
b = image->comps[2].data;
|
b = image->comps[2].data;
|
||||||
a = image->comps[3].data;
|
if(has_alpha) {
|
||||||
|
a = image->comps[3].data;
|
||||||
|
}
|
||||||
|
|
||||||
for(i = 0; i < height; ++i)
|
for(i = 0; i < height; ++i)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue