[FFmpeg-cvslog] avcodec/hevc: drop redundant ifs()

Michael Niedermayer git at videolan.org
Thu Feb 5 22:38:17 CET 2015


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Thu Feb  5 22:29:55 2015 +0100| [43b1fd5bb4ef0dd72f98a984d76690e28bbf7f32] | committer: Michael Niedermayer

avcodec/hevc: drop redundant ifs()

Found-by: Clément Bœsch <u at pkh.me>
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=43b1fd5bb4ef0dd72f98a984d76690e28bbf7f32
---

 libavcodec/hevc.c |    6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/libavcodec/hevc.c b/libavcodec/hevc.c
index afbfda1..e67827b 100644
--- a/libavcodec/hevc.c
+++ b/libavcodec/hevc.c
@@ -335,10 +335,8 @@ static int set_sps(HEVCContext *s, const HEVCSPS *sps)
     ff_videodsp_init (&s->vdsp,    sps->bit_depth);
 
     for (i = 0; i < 3; i++) {
-        if (s->sao_pixel_buffer_h[i])
-            av_freep(&s->sao_pixel_buffer_h[i]);
-        if (s->sao_pixel_buffer_v[i])
-            av_freep(&s->sao_pixel_buffer_v[i]);
+        av_freep(&s->sao_pixel_buffer_h[i]);
+        av_freep(&s->sao_pixel_buffer_v[i]);
     }
 
     if (sps->sao_enabled && !s->avctx->hwaccel) {



More information about the ffmpeg-cvslog mailing list