aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/timezone-timedated.cpp2
-rw-r--r--tests/timedated-fixture.h6
2 files changed, 5 insertions, 3 deletions
diff --git a/src/timezone-timedated.cpp b/src/timezone-timedated.cpp
index 778697a..bfe38f4 100644
--- a/src/timezone-timedated.cpp
+++ b/src/timezone-timedated.cpp
@@ -195,6 +195,8 @@ out:
/* Incase something breaks, we don't want to hang */
m_timeout_id = g_timeout_add(500, quit_loop, this);
+
+ /* We need to block until we've read the tz once */
g_main_loop_run(m_loop);
}
diff --git a/tests/timedated-fixture.h b/tests/timedated-fixture.h
index e75e6bd..0e89ea1 100644
--- a/tests/timedated-fixture.h
+++ b/tests/timedated-fixture.h
@@ -80,9 +80,9 @@ private:
auto self = static_cast<TimedateFixture*>(gself);
g_debug("bus acquired: %s, connection is %p", name, conn);
- // Set up a mock GSD.
- // All it really does is wait for calls to GetDevice and
- // returns the get_devices_retval variant
+ /* Set up a fake timedated which handles setting and getting the
+ ** timezone
+ */
static const GDBusInterfaceVTable vtable = {
timedate1_handle_method_call,
timedate1_get_properties, /* GetProperty */