[FFmpeg-devel] [PATCH 2/5] doc/examples/qsv_transcode: Simplify loop

Michael Niedermayer michael at niedermayer.cc
Thu Apr 25 00:05:09 EEST 2024


On Wed, Apr 24, 2024 at 05:25:11AM +0000, Xiang, Haihao wrote:
> On Wo, 2024-04-24 at 03:45 +0200, Michael Niedermayer wrote:
> > Fixes: CID1428858(2/2) Logically dead code
> > 
> > Sponsored-by: Sovereign Tech Fund
> > Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> > ---
> >  doc/examples/qsv_transcode.c | 4 +---
> >  1 file changed, 1 insertion(+), 3 deletions(-)
> > 
> > diff --git a/doc/examples/qsv_transcode.c b/doc/examples/qsv_transcode.c
> > index 8e7d2899f12..a4440a3403f 100644
> > --- a/doc/examples/qsv_transcode.c
> > +++ b/doc/examples/qsv_transcode.c
> > @@ -335,10 +335,8 @@ static int dec_enc(AVPacket *pkt, const AVCodec
> > *enc_codec, char *optstr)
> >  
> >  fail:
> >          av_frame_free(&frame);
> > -        if (ret < 0)
> > -            return ret;
> >      }
> > -    return 0;
> > +    return ret;
> >  }
> >  
> >  int main(int argc, char **argv)
> 
> LGTM

will apply

thx

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Take away the freedom of one citizen and you will be jailed, take away
the freedom of all citizens and you will be congratulated by your peers
in Parliament.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20240424/bba1cf28/attachment.sig>


More information about the ffmpeg-devel mailing list