owntone-server/src/conffile.h

31 lines
860 B
C
Raw Normal View History

#ifndef __CONFFILE_H__
#define __CONFFILE_H__
#include <sys/types.h>
2020-02-01 16:15:56 -05:00
#include <stdint.h>
2009-04-18 11:18:37 -04:00
#include <confuse.h>
#define CONFFILE CONFDIR "/owntone.conf"
2009-06-12 05:09:58 -04:00
// Some shorthand macros for poor man's
#define CFG_NAME_UNKNOWN_TITLE (cfg_getstr(cfg_getsec(cfg, "library"), "name_unknown_title"))
#define CFG_NAME_UNKNOWN_ARTIST (cfg_getstr(cfg_getsec(cfg, "library"), "name_unknown_artist"))
#define CFG_NAME_UNKNOWN_ALBUM (cfg_getstr(cfg_getsec(cfg, "library"), "name_unknown_album"))
#define CFG_NAME_UNKNOWN_GENRE (cfg_getstr(cfg_getsec(cfg, "library"), "name_unknown_genre"))
#define CFG_NAME_UNKNOWN_COMPOSER (cfg_getstr(cfg_getsec(cfg, "library"), "name_unknown_composer"))
2009-04-18 11:18:37 -04:00
extern cfg_t *cfg;
extern uint64_t libhash;
extern uid_t runas_uid;
extern gid_t runas_gid;
int
conffile_load(char *file);
void
conffile_unload(void);
#endif /* !__CONFFILE_H__ */