summaryrefslogtreecommitdiff
path: root/src/daemon/daemon.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/daemon/daemon.c')
-rw-r--r--src/daemon/daemon.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/daemon/daemon.c b/src/daemon/daemon.c
index ada9a2d..821de3e 100644
--- a/src/daemon/daemon.c
+++ b/src/daemon/daemon.c
@@ -182,20 +182,20 @@ static gboolean do_exit(gpointer user_data)
static void add_exit_timeout(NotifyDaemon* daemon)
{
+ g_assert_nonnull(daemon);
+
if (daemon->priv->exit_timeout_source > 0)
- {
return;
- }
daemon->priv->exit_timeout_source = g_timeout_add_seconds(IDLE_SECONDS, do_exit, NULL);
}
static void remove_exit_timeout(NotifyDaemon* daemon)
{
+ g_assert_nonnull(daemon);
+
if (daemon->priv->exit_timeout_source == 0)
- {
return;
- }
g_source_remove(daemon->priv->exit_timeout_source);
daemon->priv->exit_timeout_source = 0;