diff --git a/pressure-vessel/launcher.c b/pressure-vessel/launcher.c index 4acd2c1f28ac4438ca41414a8a5b56a427c48a2c..d22b5a26db3b501cc44fa0d71acca31331e7b5df 100644 --- a/pressure-vessel/launcher.c +++ b/pressure-vessel/launcher.c @@ -284,14 +284,14 @@ handle_launch (PvLauncher1 *object, g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No command given"); - return TRUE; + return G_DBUS_METHOD_INVOCATION_HANDLED; } if ((arg_flags & ~PV_LAUNCH_FLAGS_MASK) != 0) { g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "Unsupported flags enabled: 0x%x", arg_flags & ~PV_LAUNCH_FLAGS_MASK); - return TRUE; + return G_DBUS_METHOD_INVOCATION_HANDLED; } g_variant_lookup (arg_options, "terminate-after", "b", &terminate_after); @@ -449,7 +449,7 @@ handle_launch (PvLauncher1 *object, g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, code, "Failed to start command: %s", error->message); - return TRUE; + return G_DBUS_METHOD_INVOCATION_HANDLED; } pid_data = g_new0 (PidData, 1); @@ -469,7 +469,7 @@ handle_launch (PvLauncher1 *object, pid_data); pv_launcher1_complete_launch (object, invocation, NULL, pid); - return TRUE; + return G_DBUS_METHOD_INVOCATION_HANDLED; } static gboolean @@ -491,7 +491,7 @@ handle_send_signal (PvLauncher1 *object, g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNIX_PROCESS_ID_UNKNOWN, "No such pid"); - return TRUE; + return G_DBUS_METHOD_INVOCATION_HANDLED; } g_debug ("Sending signal %d to client pid %d", arg_signal, arg_pid); @@ -503,7 +503,7 @@ handle_send_signal (PvLauncher1 *object, pv_launcher1_complete_send_signal (launcher, invocation); - return TRUE; + return G_DBUS_METHOD_INVOCATION_HANDLED; } static gboolean @@ -513,7 +513,7 @@ handle_terminate (PvLauncher1 *object, terminate_children (SIGTERM); pv_launcher1_complete_terminate (object, invocation); unref_skeleton_in_timeout (); - return TRUE; /* handled */ + return G_DBUS_METHOD_INVOCATION_HANDLED; } static void @@ -812,10 +812,10 @@ new_connection_cb (GDBusServer *server, { g_warning ("Unable to export object: %s", error->message); g_dbus_connection_close (connection, NULL, NULL, NULL); - return TRUE; /* handled, unsuccessfully */ + return G_DBUS_METHOD_INVOCATION_HANDLED; } - return TRUE; + return G_DBUS_METHOD_INVOCATION_HANDLED; } static GDBusServer * diff --git a/steam-runtime-tools/glib-backports-internal.h b/steam-runtime-tools/glib-backports-internal.h index 2aeed240181f1145dd81b5b328e72f4556971ddb..805f2ef099a1584579a12e3c3a835173556968ad 100644 --- a/steam-runtime-tools/glib-backports-internal.h +++ b/steam-runtime-tools/glib-backports-internal.h @@ -109,3 +109,8 @@ gchar *my_g_canonicalize_filename (const gchar *filename, gpointer *my_g_hash_table_get_keys_as_array (GHashTable *hash, guint *len); #endif + +#if !GLIB_CHECK_VERSION (2, 67, 0) +#define G_DBUS_METHOD_INVOCATION_HANDLED TRUE +#define G_DBUS_METHOD_INVOCATION_UNHANDLED FALSE +#endif