aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2016-11-04 11:00:24 -0500
committerRobert Tari <robert@tari.in>2021-07-09 00:17:07 +0200
commit46d007f0e15aba176d191d349f8a916ee77d5a72 (patch)
treeea62401b3fa651de352b9a0a75e3ff4ef49a8f67 /src
parentc7e9bdbf4fad2a8975d6d6e03d61122c878f1552 (diff)
downloadayatana-indicator-datetime-46d007f0e15aba176d191d349f8a916ee77d5a72.tar.gz
ayatana-indicator-datetime-46d007f0e15aba176d191d349f8a916ee77d5a72.tar.bz2
ayatana-indicator-datetime-46d007f0e15aba176d191d349f8a916ee77d5a72.zip
remove unnecessary test in Awake::Impl::~Impl()
Diffstat (limited to 'src')
-rw-r--r--src/awake.cpp11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/awake.cpp b/src/awake.cpp
index 3bcd8ed..9ee337e 100644
--- a/src/awake.cpp
+++ b/src/awake.cpp
@@ -62,12 +62,8 @@ public:
{
g_cancellable_cancel (m_cancellable);
g_object_unref (m_cancellable);
-
- if (m_system_bus != nullptr)
- {
- unforce_awake ();
- g_object_unref (m_system_bus);
- }
+ unforce_awake ();
+ g_clear_object (&m_system_bus);
}
private:
@@ -99,7 +95,6 @@ private:
g_clear_pointer (&self->m_awake_cookie, g_free);
g_variant_get (args, "(s)", &self->m_awake_cookie);
- g_debug ("m_awake_cookie is now '%s'", self->m_awake_cookie);
g_variant_unref (args);
}
@@ -120,7 +115,7 @@ private:
nullptr,
G_DBUS_CALL_FLAGS_NONE,
-1,
- nullptr,
+ m_cancellable,
nullptr,
nullptr);