On 10/8/19 11:01 AM, Alexandre Julliard wrote:
Rémi Bernon rbernon@codeweavers.com writes:
+static int rtkit_set_realtime( dbus_uint64_t process, dbus_uint64_t thread, dbus_uint32_t priority ) +{
- DBusConnection* dbus = NULL;
- DBusMessage *msg = NULL, *rep = NULL;
- DBusError err;
- int ret = -1;
- dbus_error_init(&err);
- dbus = dbus_bus_get_private(DBUS_BUS_SYSTEM, &err);
- if (dbus_error_is_set(&err))
goto error;
- dbus_connection_set_exit_on_disconnect(dbus, 0);
- if (!(msg = dbus_message_new_method_call("org.freedesktop.RealtimeKit1",
"/org/freedesktop/RealtimeKit1",
"org.freedesktop.RealtimeKit1",
"MakeThreadRealtimeWithPID")))
goto error;
- if (!dbus_message_append_args(msg,
DBUS_TYPE_UINT64, &process,
DBUS_TYPE_UINT64, &thread,
DBUS_TYPE_UINT32, &priority,
DBUS_TYPE_INVALID))
goto error;
- if (!(rep = dbus_connection_send_with_reply_and_block(dbus, msg, -1, &err)))
goto error;
I don't think we want to make blocking dbus calls from wineserver.
Sure, and we ignore errors anyway. I'll replace that with dbus_connection_send.