diff options
author | Ingo Schwarze <schwarze@openbsd.org> | 2015-03-27 17:37:25 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@openbsd.org> | 2015-03-27 17:37:25 +0000 |
commit | aeaacb622a48de841df3d2733d63ed99db74ffbc (patch) | |
tree | 26003bbc829278be3b4b17ea680abf1917792058 /manpage.c | |
parent | 2fba111e1348dcdc89a477c59777c7ad13b08029 (diff) | |
download | mandoc-aeaacb622a48de841df3d2733d63ed99db74ffbc.tar.gz |
Parse the new man.conf(5) "output" directive.
The next step will be to actually use the parsed data.
Diffstat (limited to 'manpage.c')
-rw-r--r-- | manpage.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -28,7 +28,7 @@ #include <string.h> #include <unistd.h> -#include "manpath.h" +#include "manconf.h" #include "mansearch.h" static void show(const char *, const char *); @@ -43,7 +43,7 @@ main(int argc, char *argv[]) char *conf_file, *defpaths, *auxpaths, *cp; char buf[PATH_MAX]; const char *cmd; - struct manpaths paths; + struct manconf conf; char *progname; extern char *optarg; extern int optind; @@ -57,7 +57,7 @@ main(int argc, char *argv[]) ++progname; auxpaths = defpaths = conf_file = NULL; - memset(&paths, 0, sizeof(struct manpaths)); + memset(&conf, 0, sizeof(conf)); memset(&search, 0, sizeof(struct mansearch)); while (-1 != (ch = getopt(argc, argv, "C:M:m:S:s:"))) @@ -90,9 +90,9 @@ main(int argc, char *argv[]) search.outkey = "Nd"; search.argmode = ARG_EXPR; - manpath_parse(&paths, conf_file, defpaths, auxpaths); - ch = mansearch(&search, &paths, argc, argv, &res, &sz); - manpath_free(&paths); + manconf_parse(&conf, conf_file, defpaths, auxpaths); + ch = mansearch(&search, &conf.manpath, argc, argv, &res, &sz); + manconf_free(&conf); if (0 == ch) goto usage; |