Message ID | 20200308154947.25191-1-andriy.gelman@gmail.com |
---|---|
State | Accepted |
Headers | show |
Series | [FFmpeg-devel] lavc/v4l2_m2m_dec: Init reserved bytes to zero before ioctl call | expand |
Context | Check | Description |
---|---|---|
andriy/ffmpeg-patchwork | success | Make fate finished |
On Sun, 08. Mar 11:49, Andriy Gelman wrote: > From: Andriy Gelman <andriy.gelman@gmail.com> > > struct v4l2_selection contains reserved bytes which should be set to > zero before the ioctl call. > > Fixes valgrind error: > Syscall param ioctl(VKI_V4L2_S_SELECTION) points to uninitialised byte(s) > > Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com> > --- > libavcodec/v4l2_m2m_dec.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/libavcodec/v4l2_m2m_dec.c b/libavcodec/v4l2_m2m_dec.c > index d666edffe46..c5ee86b9935 100644 > --- a/libavcodec/v4l2_m2m_dec.c > +++ b/libavcodec/v4l2_m2m_dec.c > @@ -39,7 +39,7 @@ static int v4l2_try_start(AVCodecContext *avctx) > V4L2m2mContext *s = ((V4L2m2mPriv*)avctx->priv_data)->context; > V4L2Context *const capture = &s->capture; > V4L2Context *const output = &s->output; > - struct v4l2_selection selection; > + struct v4l2_selection selection = { 0 }; > int ret; > > /* 1. start the output process */ > -- > 2.25.0 > ping
On Thu, 12. Mar 22:40, Andriy Gelman wrote: > On Sun, 08. Mar 11:49, Andriy Gelman wrote: > > From: Andriy Gelman <andriy.gelman@gmail.com> > > > > struct v4l2_selection contains reserved bytes which should be set to > > zero before the ioctl call. > > > > Fixes valgrind error: > > Syscall param ioctl(VKI_V4L2_S_SELECTION) points to uninitialised byte(s) > > > > Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com> > > --- > > libavcodec/v4l2_m2m_dec.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/libavcodec/v4l2_m2m_dec.c b/libavcodec/v4l2_m2m_dec.c > > index d666edffe46..c5ee86b9935 100644 > > --- a/libavcodec/v4l2_m2m_dec.c > > +++ b/libavcodec/v4l2_m2m_dec.c > > @@ -39,7 +39,7 @@ static int v4l2_try_start(AVCodecContext *avctx) > > V4L2m2mContext *s = ((V4L2m2mPriv*)avctx->priv_data)->context; > > V4L2Context *const capture = &s->capture; > > V4L2Context *const output = &s->output; > > - struct v4l2_selection selection; > > + struct v4l2_selection selection = { 0 }; > > int ret; > > > > /* 1. start the output process */ > > -- > > 2.25.0 > > > > ping > ping
On Sun, Mar 08, 2020 at 11:49:47AM -0400, Andriy Gelman wrote: > From: Andriy Gelman <andriy.gelman@gmail.com> > > struct v4l2_selection contains reserved bytes which should be set to > zero before the ioctl call. > > Fixes valgrind error: > Syscall param ioctl(VKI_V4L2_S_SELECTION) points to uninitialised byte(s) > > Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com> > --- > libavcodec/v4l2_m2m_dec.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) probably ok thx [...]
On Wed, 01. Apr 00:38, Michael Niedermayer wrote: > On Sun, Mar 08, 2020 at 11:49:47AM -0400, Andriy Gelman wrote: > > From: Andriy Gelman <andriy.gelman@gmail.com> > > > > struct v4l2_selection contains reserved bytes which should be set to > > zero before the ioctl call. > > > > Fixes valgrind error: > > Syscall param ioctl(VKI_V4L2_S_SELECTION) points to uninitialised byte(s) > > > > Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com> > > --- > > libavcodec/v4l2_m2m_dec.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > probably ok > > thx > Applied. Thanks,
diff --git a/libavcodec/v4l2_m2m_dec.c b/libavcodec/v4l2_m2m_dec.c index d666edffe46..c5ee86b9935 100644 --- a/libavcodec/v4l2_m2m_dec.c +++ b/libavcodec/v4l2_m2m_dec.c @@ -39,7 +39,7 @@ static int v4l2_try_start(AVCodecContext *avctx) V4L2m2mContext *s = ((V4L2m2mPriv*)avctx->priv_data)->context; V4L2Context *const capture = &s->capture; V4L2Context *const output = &s->output; - struct v4l2_selection selection; + struct v4l2_selection selection = { 0 }; int ret; /* 1. start the output process */