From 2d230e3e762e9ff543b4d037696a79ff9c328dcf Mon Sep 17 00:00:00 2001 From: NeilBrown Date: Tue, 6 Dec 2016 12:44:12 -0500 Subject: conffile: add bool support conf_get_bool() interprets various strings as 'true' or 'false'. If no suitable value is found, the default is returned. Signed-off-by: NeilBrown Signed-off-by: Steve Dickson --- support/include/conffile.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'support/include/conffile.h') diff --git a/support/include/conffile.h b/support/include/conffile.h index a6d5846..3fe3a78 100644 --- a/support/include/conffile.h +++ b/support/include/conffile.h @@ -36,6 +36,7 @@ #include #include #include +#include struct conf_list_node { TAILQ_ENTRY(conf_list_node) link; @@ -57,6 +58,7 @@ extern struct sockaddr *conf_get_address(char *, char *); extern struct conf_list *conf_get_list(char *, char *); extern struct conf_list *conf_get_tag_list(char *, char *); extern int conf_get_num(char *, char *, int); +extern _Bool conf_get_bool(char *, char *, _Bool); extern char *conf_get_str(char *, char *); extern char *conf_get_section(char *, char *, char *); extern void conf_init(void); -- cgit