connman.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
* [PATCH] main: Set default online check URL also when no config provided
@ 2022-02-27 17:15 Daniel Wagner
  2022-02-27 17:18 ` Daniel Wagner
  0 siblings, 1 reply; 2+ messages in thread
From: Daniel Wagner @ 2022-02-27 17:15 UTC (permalink / raw)
  To: connman; +Cc: daniel antoine, Daniel Wagner

We need to set the default URL also when no config exist.

Reported by: Daniel Antoine <univac55@gmail.com>

Fixes: 9d7e55f40e80 ("wispr: Add online check url config options")
---
 src/main.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/src/main.c b/src/main.c
index e209cf261300..bf6ccad5fc08 100644
--- a/src/main.c
+++ b/src/main.c
@@ -318,11 +318,17 @@ static void parse_config(GKeyFile *config)
 
 	if (!config) {
 		connman_settings.auto_connect =
-			parse_service_types(default_auto_connect, CONF_ARRAY_SIZE(default_auto_connect));
+			parse_service_types(default_auto_connect,
+					CONF_ARRAY_SIZE(default_auto_connect));
 		connman_settings.favorite_techs =
-			parse_service_types(default_favorite_techs, CONF_ARRAY_SIZE(default_favorite_techs));
+			parse_service_types(default_favorite_techs,
+					CONF_ARRAY_SIZE(default_favorite_techs));
 		connman_settings.blacklisted_interfaces =
 			g_strdupv(default_blacklist);
+		connman_settings.online_check_ipv4_url =
+			g_strdup(DEFAULT_ONLINE_CHECK_IPV4_URL);
+		connman_settings.online_check_ipv6_url =
+			g_strdup(DEFAULT_ONLINE_CHECK_IPV6_URL);
 		return;
 	}
 
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] main: Set default online check URL also when no config provided
  2022-02-27 17:15 [PATCH] main: Set default online check URL also when no config provided Daniel Wagner
@ 2022-02-27 17:18 ` Daniel Wagner
  0 siblings, 0 replies; 2+ messages in thread
From: Daniel Wagner @ 2022-02-27 17:18 UTC (permalink / raw)
  To: Daniel Wagner, connman; +Cc: daniel antoine

On Sun, 27 Feb 2022 18:15:49 +0100, Daniel Wagner wrote:
> We need to set the default URL also when no config exist.
> 
> Reported by: Daniel Antoine <univac55@gmail.com>
> 
> 

Applied, thanks!

[1/1] main: Set default online check URL also when no config provided
      commit: d48584aa8bed06f9b728579ea64deb8d30b03b86

Best regards,
-- 
Daniel Wagner <wagi@monom.org>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-02-27 17:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-27 17:15 [PATCH] main: Set default online check URL also when no config provided Daniel Wagner
2022-02-27 17:18 ` Daniel Wagner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).