diff --git a/src/hcid.h b/src/hcid.h
index ea67cc2..6040c71 100644
--- a/src/hcid.h
+++ b/src/hcid.h
void rfkill_init(void);
void rfkill_exit(void);
+GKeyFile *btd_get_main_conf(void);
+
void btd_exit(void);
diff --git a/src/main.c b/src/main.c
index b3136fc..be757d7 100644
--- a/src/main.c
+++ b/src/main.c
#define SHUTDOWN_GRACE_SECONDS 10
struct main_opts main_opts;
+GKeyFile *main_conf;
static const char * const supported_options[] = {
"Name",
"DebugKeys",
};
+GKeyFile *btd_get_main_conf(void)
+{
+ return main_conf;
+}
+
static GKeyFile *load_config(const char *file)
{
GError *err = NULL;
uint16_t sdp_mtu = 0;
uint32_t sdp_flags = 0;
int gdbus_flags = 0;
- GKeyFile *config;
guint signal, watchdog;
const char *watchdog_usec;
sd_notify(0, "STATUS=Starting up");
- config = load_config(CONFIGDIR "/main.conf");
+ main_conf = load_config(CONFIGDIR "/main.conf");
- parse_config(config);
+ parse_config(main_conf);
if (connect_dbus() < 0) {
error("Unable to get on D-Bus");
g_main_loop_unref(event_loop);
- if (config)
- g_key_file_free(config);
+ if (main_conf)
+ g_key_file_free(main_conf);
disconnect_dbus();