Opened 5 years ago

Closed 4 years ago

#8172 closed defect (fixed)

Assertion at libavformat/avienc.c:800

Reported by: Suhwan Owned by:
Priority: important Component: avformat
Version: git-master Keywords: avi crash abort regression
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: no

Description

Summary of the bug:
There're Assertion at libavformat/avienc.c:800 and 3 shift exponent 32 is too large for 32-bit type 'int' bugs

libavformat/riffenc.c:242:31: runtime error: shift exponent 32 is too large for 32-bit type 'int'
libavformat/riffenc.c:252:31: runtime error: shift exponent 32 is too large for 32-bit type 'int'
libavformat/avienc.c:797:34: runtime error: shift exponent 32 is too large for 32-bit type 'int'

Assertion par->bits_per_coded_sample >= 0 && par->bits_per_coded_sample <= 8 failed at libavformat/avienc.c:800

How to reproduce:

% ./ffmpeg_g -t 3 -stream_loop 2 -y -i Airplane.mov -loglevel 99 -map 0 -c copy -vframes 87 -ar 48000 tmp.avi

ffmpeg version N-94957-g65589ad553 Copyright (c) 2000-2019 the FFmpeg developers
  built with clang version 6.0.0-1ubuntu2 (tags/RELEASE_600/final)
  configuration: --cc=clang --cxx=clang++ --ld=clang --enable-debug --toolchain=clang-usan

Attachments (2)

gdb-aborted (23.2 KB ) - added by Suhwan 5 years ago.
Airplane.mov (528.6 KB ) - added by Suhwan 5 years ago.
poc

Download all attachments as: .zip

Change History (4)

by Suhwan, 5 years ago

Attachment: gdb-aborted added

by Suhwan, 5 years ago

Attachment: Airplane.mov added

poc

comment:1 by Carl Eugen Hoyos, 4 years ago

Keywords: avi ubsan crash abort regression added; assertion removed
Priority: normalimportant
Reproduced by developer: set

The assertion failure is a regression since e0f5f9267a8bc104ec3cefe03873dd2508c46650

comment:2 by Carl Eugen Hoyos, 4 years ago

Component: undeterminedavformat
Keywords: ubsan removed
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.