aboutsummaryrefslogtreecommitdiffstats
path: root/cmdutils.c
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2007-08-13 23:03:36 +0000
committerDiego Biurrun <diego@biurrun.de>2007-08-13 23:03:36 +0000
commit60a9966e4d96ca26ceabdaf99eacfb0872c4e931 (patch)
tree8f8337270ddeeb6f17b527ad9e1cbc8301f76b4a /cmdutils.c
parent9c0edaaf1359b4eeb26870c74c3a00dfd026de67 (diff)
downloadffmpeg-60a9966e4d96ca26ceabdaf99eacfb0872c4e931.tar.gz
Make cmdutils.c:parse_options accept as argument a function to parse
bare command line parameters. patch by Stefano Sabatini, stefano.sabatini-lala poste it Originally committed as revision 10112 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'cmdutils.c')
-rw-r--r--cmdutils.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/cmdutils.c b/cmdutils.c
index 1c2f44ef3c..a436031d3f 100644
--- a/cmdutils.c
+++ b/cmdutils.c
@@ -61,7 +61,8 @@ static const OptionDef* find_option(const OptionDef *po, const char *name){
return po;
}
-void parse_options(int argc, char **argv, const OptionDef *options)
+void parse_options(int argc, char **argv, const OptionDef *options,
+ void (* parse_arg_function)(const char*))
{
const char *opt, *arg;
int optindex, handleoptions=1;
@@ -112,7 +113,8 @@ unknown_opt:
po->u.func_arg(arg);
}
} else {
- parse_arg_file(opt);
+ if (parse_arg_function)
+ parse_arg_function(opt);
}
}
}