6 * ciniparser - easily parse and manipulate ini style configuration files
7 * A dictionary object is allocated which contains string keys and values.
8 * Functions to read string values return statically allocated objects,
9 * there is no need to free them (also, do not modify them directly).
11 * Additional functions to manipulate or unset objects in the dictionary
12 * can be found in the test suite.
17 * #include <stdbool.h>
18 * #include <ccan/ciniparser/ciniparser.h>
20 * #define CONFIG_FILE "/etc/config.ini"
22 * int main(int argc, char *argv[])
30 * d = ciniparser_load(CONFIG_FILE);
34 * val1 = ciniparser_getstring(d, "daemon:pidfile", NULL);
35 * val2 = ciniparser_getboolean(d, "daemon:debug", false);
36 * val3 = ciniparser_getdouble(d, "daemon:maxload", 3.5);
37 * val4 = ciniparser_getint(d, "daemon:maxchild", 5);
39 * ciniparser_freedict(d);
46 int main(int argc, char *argv[])
51 if (strcmp(argv[1], "depends") == 0) {