aboutsummaryrefslogtreecommitdiffstats
path: root/cmdutils.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-12-20 02:15:40 +0100
committerMichael Niedermayer <michaelni@gmx.at>2012-12-20 02:38:18 +0100
commitba4bcb191aa8b5fa66131544bf9ebf1f17ff7d9a (patch)
treee909f00e8244b8d81ce919ba15f8af9bab1dc1fa /cmdutils.c
parentaf4b1c02acf6923489d30349c4813a0d73b2f114 (diff)
downloadffmpeg-ba4bcb191aa8b5fa66131544bf9ebf1f17ff7d9a.tar.gz
cmdutils: implement debug/fdebug log level update differently.
The old implementation is no longer possibly due to limitations of the new command line parser. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'cmdutils.c')
-rw-r--r--cmdutils.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/cmdutils.c b/cmdutils.c
index c1b81a176b..31c6ad618a 100644
--- a/cmdutils.c
+++ b/cmdutils.c
@@ -480,6 +480,9 @@ int opt_default(void *optctx, const char *opt, const char *arg)
const AVClass *cc = avcodec_get_class(), *fc = avformat_get_class();
const AVClass *sc, *swr_class;
+ if (!strcmp(opt, "debug") || !strcmp(opt, "fdebug"))
+ av_log_set_level(AV_LOG_DEBUG);
+
if (!(p = strchr(opt, ':')))
p = opt + strlen(opt);
av_strlcpy(opt_stripped, opt, FFMIN(sizeof(opt_stripped), p - opt + 1));
@@ -909,12 +912,6 @@ int opt_cpuflags(void *optctx, const char *opt, const char *arg)
return 0;
}
-int opt_codec_debug(void *optctx, const char *opt, const char *arg)
-{
- av_log_set_level(AV_LOG_DEBUG);
- return opt_default(NULL, opt, arg);
-}
-
int opt_timelimit(void *optctx, const char *opt, const char *arg)
{
#if HAVE_SETRLIMIT