cmdutils: print a more descriptive error message in show_help_bsf() when no bsf is...
authorJames Almer <jamrial@gmail.com>
Sat, 28 Jul 2018 03:58:29 +0000 (00:58 -0300)
committerJames Almer <jamrial@gmail.com>
Sat, 28 Jul 2018 14:14:45 +0000 (11:14 -0300)
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
fftools/cmdutils.c

index b8de319..9cfbc45 100644 (file)
@@ -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;
     }