[gnome-session] main: Fix a g_spawn() deprecation



commit c45cd9653ef8fbc87023ff2dd04fb3cdd4c33ed1
Author: Philip Withnall <pwithnall endlessos org>
Date:   Mon Nov 15 18:50:16 2021 +0000

    main: Fix a g_spawn() deprecation
    
    `g_spawn_check_exit_status()` was deprecated in GLib 2.70 since it was
    misnamed.
    
    I have checked that the `status` here is actually a wait status, not an
    exit status.
    
    Signed-off-by: Philip Withnall <pwithnall endlessos org>

 gnome-session/main.c | 4 ++++
 1 file changed, 4 insertions(+)
---
diff --git a/gnome-session/main.c b/gnome-session/main.c
index 443bc045..84df6ce7 100644
--- a/gnome-session/main.c
+++ b/gnome-session/main.c
@@ -244,7 +244,11 @@ check_gl (GError **error)
                 return FALSE;
         }
 
+#if GLIB_CHECK_VERSION(2, 70, 0)
+        return g_spawn_check_wait_status (status, error);
+#else
         return g_spawn_check_exit_status (status, error);
+#endif
 }
 
 static void


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]