[FFmpeg-trac] #3413(undetermined:open): invalid read in swscale when converting from rgb24 to yuv420p
FFmpeg
trac at avcodec.org
Sun Jun 22 09:19:20 CEST 2014
#3413: invalid read in swscale when converting from rgb24 to yuv420p
-------------------------------------+-------------------------------------
Reporter: ubitux | Owner:
Type: defect | Status: open
Priority: normal | Component:
Version: git-master | undetermined
Keywords: | Resolution:
Blocking: | Blocked By:
Analyzed by developer: 0 | Reproduced by developer: 1
-------------------------------------+-------------------------------------
Comment (by ubitux):
The valgrind commands don't triggers the issue anymore. OTOH the original
code still does. The following hack prevents the valgrind issue:
{{{
--- a/libavcodec/avpicture.c
+++ b/libavcodec/avpicture.c
@@ -55,7 +55,7 @@ int avpicture_alloc(AVPicture *picture,
enum AVPixelFormat pix_fmt, int width, int height)
{
int ret = av_image_alloc(picture->data, picture->linesize,
- width, height, pix_fmt, 1);
+ width, height, pix_fmt, 32);
if (ret < 0) {
memset(picture, 0, sizeof(AVPicture));
return ret;
}}}
--
Ticket URL: <https://trac.ffmpeg.org/ticket/3413#comment:3>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list