aboutsummaryrefslogtreecommitdiffstats
path: root/src/conf.h
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2007-09-05 23:59:33 +0000
committerEric Wong <normalperson@yhbt.net>2007-09-05 23:59:33 +0000
commit4a2122eaf4bffdf7ebb012fe6348602d8e54ced0 (patch)
treeae1e3307e08d3e36e5e7a7e50960f2eae8234670 /src/conf.h
parentac58dce7df97a97b8e2d71a76b5fa8805653959a (diff)
downloadmpd-4a2122eaf4bffdf7ebb012fe6348602d8e54ced0.tar.gz
mpd-4a2122eaf4bffdf7ebb012fe6348602d8e54ced0.tar.xz
mpd-4a2122eaf4bffdf7ebb012fe6348602d8e54ced0.zip
conf: improved boolean config parameter handling from -ke
the force flag will issue FATAL() if an invalid value is specified git-svn-id: https://svn.musicpd.org/mpd/trunk@6857 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to '')
-rw-r--r--src/conf.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/conf.h b/src/conf.h
index f5ef07525..01337d349 100644
--- a/src/conf.h
+++ b/src/conf.h
@@ -64,6 +64,9 @@
#define CONF_SAVE_ABSOLUTE_PATHS "save_absolute_paths_in_playlists"
#define CONF_GAPLESS_MP3_PLAYBACK "gapless_mp3_playback"
+#define CONF_BOOL_UNSET -1
+#define CONF_BOOL_INVALID -2
+
typedef struct _BlockParam {
char *name;
char *value;
@@ -90,10 +93,12 @@ ConfigParam *getNextConfigParam(char *name, ConfigParam * last);
char *getConfigParamValue(char *name);
-int getBoolConfigParam(char *name);
-
BlockParam *getBlockParam(ConfigParam * param, char *name);
ConfigParam *parseConfigFilePath(char *name, int force);
+int getBoolConfigParam(char *name, int force);
+
+int getBoolBlockParam(ConfigParam *param, char *name, int force);
+
#endif