From 180cf09933b2d8eb03972c8638063429fe5fece5 Mon Sep 17 00:00:00 2001 From: Luiz Augusto von Dentz Date: Wed, 13 Apr 2022 15:21:00 -0700 Subject: policy: Change AutoEnable default to true This changes the default of AutoEnable to true so controllers are power up by default. Fixes: https://github.com/bluez/bluez/issues/328 --- plugins/policy.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'plugins') diff --git a/plugins/policy.c b/plugins/policy.c index 48f5db7d3..0bbdbfc88 100644 --- a/plugins/policy.c +++ b/plugins/policy.c @@ -892,7 +892,11 @@ static int policy_init(void) } auto_enable = g_key_file_get_boolean(conf, "Policy", "AutoEnable", - NULL); + &gerr); + if (gerr) { + g_clear_error(&gerr); + auto_enable = true; + } resume_delay = g_key_file_get_integer( conf, "Policy", "ResumeDelay", &gerr); -- cgit v1.2.1