From 3bd78eb2faf09635b8d307e4440ccb1420f80716 Mon Sep 17 00:00:00 2001 From: Jakub Hrozek Date: Sun, 19 May 2013 17:36:54 +0200 Subject: Fix dyndns timer initialization The dyndns init function was starting the timer even if the updates were set to False. This patch splits the init of dynamic updates and the timer into two functions so that the back end can start the updates separately from reading the options. --- src/providers/ipa/ipa_dyndns.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/providers/ipa/ipa_dyndns.c') diff --git a/src/providers/ipa/ipa_dyndns.c b/src/providers/ipa/ipa_dyndns.c index 81dae94a5..4e75a197a 100644 --- a/src/providers/ipa/ipa_dyndns.c +++ b/src/providers/ipa/ipa_dyndns.c @@ -44,6 +44,13 @@ errno_t ipa_dyndns_init(struct be_ctx *be_ctx, return EINVAL; } + ret = be_nsupdate_init_timer(ctx->dyndns_ctx, be_ctx->ev, + ipa_dyndns_timer, ctx); + if (ret != EOK) { + DEBUG(SSSDBG_CRIT_FAILURE, ("Could not set up periodic update\n")); + return ret; + } + ret = be_add_online_cb(be_ctx, be_ctx, ipa_dyndns_update, ctx, NULL); -- cgit