From 527186cef3d87c641e0f767a59a6f23d24118e72 Mon Sep 17 00:00:00 2001 From: Benjamin Berg Date: Wed, 10 Mar 2021 11:43:00 +0100 Subject: session: Initialize DBus error domain before resolving errors We would not initialize the DBus error domain before we retrieved the first error, but only did so to compare the error after receiving them. This means that the first error we received will not be resolved correctly, while all subsequent ones are resolved. Fix this by calling GDM_SESSION_WORKER_ERROR from gdm_session_class_init and add gdm_dbus_error_ensure to make sure this can never be optimized away. --- daemon/gdm-session.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'daemon/gdm-session.c') diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c index a6f00b66..5c5903a4 100644 --- a/daemon/gdm-session.c +++ b/daemon/gdm-session.c @@ -3998,6 +3998,9 @@ gdm_session_class_init (GdmSessionClass *session_class) FALSE, G_PARAM_READWRITE | G_PARAM_CONSTRUCT | G_PARAM_STATIC_STRINGS)); #endif + + /* Ensure we can resolve errors */ + gdm_dbus_error_ensure (GDM_SESSION_WORKER_ERROR); } GdmSession * -- cgit v1.2.1