[FFmpeg-devel] [PATCH 2/2] cmdutils: print a more descriptive error message in show_help_bsf() when no bsf is specified

James Almer jamrial at gmail.com
Sat Jul 28 06:58:48 EEST 2018


Signed-off-by: James Almer <jamrial at gmail.com>
---
 fftools/cmdutils.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/fftools/cmdutils.c b/fftools/cmdutils.c
index b8de319fe4..9cfbc45c2b 100644
--- a/fftools/cmdutils.c
+++ b/fftools/cmdutils.c
@@ -1956,7 +1956,10 @@ static void show_help_bsf(const char *name)
 {
     const AVBitStreamFilter *bsf = av_bsf_get_by_name(name);
 
-    if (!bsf) {
+    if (!name) {
+        av_log(NULL, AV_LOG_ERROR, "No bitstream filter name specified.\n");
+        return;
+    } else if (!bsf) {
         av_log(NULL, AV_LOG_ERROR, "Unknown bit stream filter '%s'.\n", name);
         return;
     }
-- 
2.18.0



More information about the ffmpeg-devel mailing list