Opened 4 years ago

Closed 4 years ago

#8238 closed defect (fixed)

left shift of 255 by 24 places cannot be represented in type 'int' at libavfilter/vsrc_testsrc.c:994

Reported by: Suhwan Owned by:
Priority: normal Component: undetermined
Version: git-master Keywords: ubsan
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug:
There is a left shift of 255 by 24 places cannot be represented in type 'int' at libavfilter/vsrc_testsrc.c:994

libavfilter/vsrc_testsrc.c:994:93: runtime error: left shift of 255 by 24 places cannot be represented in type 'int'
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior libavfilter/vsrc_testsrc.c:994:93 in 

How to reproduce:

% ffmpeg_g -t 3 -y -i $PoC -filter_complex rgbtestsrc -target dv -loglevel 0 -map 0 -c:a:6 sgi -disposition:s:7 mjpeg -vframes 68 -r 47 -ar 22050 tmp.mpegtsraw

ffmpeg version N-95291-g5345965b3f 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-vsrc_testsrc994 (11.0 KB ) - added by Suhwan 4 years ago.
PoC_vsrc_test994.tga (3.5 KB ) - added by Suhwan 4 years ago.
poc

Download all attachments as: .zip

Change History (3)

by Suhwan, 4 years ago

Attachment: gdb-vsrc_testsrc994 added

by Suhwan, 4 years ago

Attachment: PoC_vsrc_test994.tga added

poc

comment:1 by Elon Musk, 4 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.