diff mbox series

[FFmpeg-devel,2/4] avfilter/vsrc_testsrc: add a return at the end of non-void functions

Message ID 20210806133120.2914-2-jamrial@gmail.com
State Accepted
Commit 83946906fb1587e99b7cca78fbaae671a13ed401
Headers show
Series [FFmpeg-devel,1/4] fftools/ffmpeg_filter: add a return at the end of non-void functions | expand

Checks

Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished
andriy/PPC64_make success Make finished
andriy/PPC64_make_fate success Make fate finished

Commit Message

James Almer Aug. 6, 2021, 1:31 p.m. UTC
Fixes compilation with GCC 11 when configured with --disable-optimizations

Signed-off-by: James Almer <jamrial@gmail.com>
---
 libavfilter/vsrc_testsrc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Paul B Mahol Aug. 6, 2021, 6:26 p.m. UTC | #1
lgtm
diff mbox series

Patch

diff --git a/libavfilter/vsrc_testsrc.c b/libavfilter/vsrc_testsrc.c
index 0ced726f5e..08686938db 100644
--- a/libavfilter/vsrc_testsrc.c
+++ b/libavfilter/vsrc_testsrc.c
@@ -718,8 +718,8 @@  static uint32_t color_gradient(unsigned index)
     case 3: return 0x0000FF + (sd <<  8);
     case 4: return 0x0000FF + (si << 16);
     case 5: return 0xFF0000 + (sd <<  0);
+    default: av_assert0(0); return 0;
     }
-    av_assert0(0);
 }
 
 static void draw_text(TestSourceContext *s, AVFrame *frame, FFDrawColor *color,