aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/opt.c
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2009-05-14 18:50:58 +0000
committerStefano Sabatini <stefano.sabatini-lala@poste.it>2009-05-14 18:50:58 +0000
commitbe1fb76fa11b0897d326782ddfb06624105a64bf (patch)
tree4fad3084145244dadb9864f72d26fac87b664755 /libavcodec/opt.c
parent50f68bdebf79146df8f010bc6bad0b8145077944 (diff)
downloadffmpeg-be1fb76fa11b0897d326782ddfb06624105a64bf.tar.gz
Make av_set_string3() print a message in case of unknown option.
Originally committed as revision 18826 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/opt.c')
-rw-r--r--libavcodec/opt.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libavcodec/opt.c b/libavcodec/opt.c
index a6abcfc2e7..c7218296f6 100644
--- a/libavcodec/opt.c
+++ b/libavcodec/opt.c
@@ -112,8 +112,10 @@ int av_set_string3(void *obj, const char *name, const char *val, int alloc, cons
const AVOption *o= av_find_opt(obj, name, NULL, 0, 0);
if (o_out)
*o_out = o;
- if(!o)
+ if(!o) {
+ av_log(obj, AV_LOG_ERROR, "Unknown option '%s'\n", name);
return AVERROR(ENOENT);
+ }
if(!val || o->offset<=0)
return AVERROR(EINVAL);