mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-12 10:15:22 +00:00
avcodec/jpeg2000dwt: Check ndeclevels before calling dwt_encode*()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit feb3f39614
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
551e18aa92
commit
6bc2f5cc0b
@ -540,6 +540,9 @@ int ff_jpeg2000_dwt_init(DWTContext *s, uint16_t border[2][2],
|
||||
|
||||
int ff_dwt_encode(DWTContext *s, void *t)
|
||||
{
|
||||
if (s->ndeclevels == 0)
|
||||
return 0;
|
||||
|
||||
switch(s->type){
|
||||
case FF_DWT97:
|
||||
dwt_encode97_float(s, t); break;
|
||||
|
Loading…
Reference in New Issue
Block a user