X-Git-Url: https://git.distorted.org.uk/~mdw/secnet/blobdiff_plain/bc07424dca80830704295cc1cfee04da75479f8c..cf5f1149caccf65c700e73fc0e9212c916df3610:/secnet.h diff --git a/secnet.h b/secnet.h index 986ef26..629851b 100644 --- a/secnet.h +++ b/secnet.h @@ -19,6 +19,8 @@ #include #include +#include + #define MAX_PEER_ADDRS 5 /* send at most this many copies; honour at most that many addresses */ @@ -138,6 +140,14 @@ extern uint32_t dict_read_number(dict_t *dict, cstring_t key, bool_t required, /* return value can safely be assigned to int32_t */ extern bool_t dict_read_bool(dict_t *dict, cstring_t key, bool_t required, cstring_t desc, struct cloc loc, bool_t def); +const char **dict_read_string_array(dict_t *dict, cstring_t key, + bool_t required, cstring_t desc, + struct cloc loc, const char *const *def); + /* Return value is a NULL-terminated array obtained from malloc; + * Individual string values are still owned by config file machinery + * and must not be modified or freed. Returns NULL if key not + * found. */ + struct flagstr { cstring_t name; uint32_t value;