Просмотр исходного кода

Issue a more general message when the function which sets an option
fails.

It may fail not only because of an invalid value for the option, but
also for other reasons, e.g. memory problems etc.

Originally committed as revision 22738 to svn://svn.ffmpeg.org/ffmpeg/trunk

Stefano Sabatini 15 лет назад
Родитель
Сommit
330d86f593
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      cmdutils.c

+ 1 - 1
cmdutils.c

@@ -170,7 +170,7 @@ unknown_opt:
                 *po->u.float_arg = parse_number_or_die(opt, arg, OPT_FLOAT, -1.0/0.0, 1.0/0.0);
                 *po->u.float_arg = parse_number_or_die(opt, arg, OPT_FLOAT, -1.0/0.0, 1.0/0.0);
             } else if (po->flags & OPT_FUNC2) {
             } else if (po->flags & OPT_FUNC2) {
                 if (po->u.func2_arg(opt, arg) < 0) {
                 if (po->u.func2_arg(opt, arg) < 0) {
-                    fprintf(stderr, "%s: invalid value '%s' for option '%s'\n", argv[0], arg, opt);
+                    fprintf(stderr, "%s: failed to set value '%s' for option '%s'\n", argv[0], arg, opt);
                     exit(1);
                     exit(1);
                 }
                 }
             } else {
             } else {