]> err.no Git - systemd/commitdiff
logind: properly generate session creation response on dbus
authorLennart Poettering <lennart@poettering.net>
Mon, 3 Oct 2011 23:38:13 +0000 (01:38 +0200)
committerKay Sievers <kay.sievers@vrfy.org>
Tue, 4 Oct 2011 00:28:22 +0000 (02:28 +0200)
This fixes the various reported issues with dbus message parsing when
running su.

src/logind-dbus.c

index b33a096f3c1076c56b3793615dcbf130cc34223e..bc1e49d18fa2cd4450bc2ddfab9a8199981f6672 100644 (file)
@@ -405,12 +405,16 @@ static int bus_manager_create_session(Manager *m, DBusMessage *message, DBusMess
                                 goto fail;
                         }
 
+                        seat = session->seat ? session->seat->id : "";
+                        vtnr = session->vtnr;
                         b = dbus_message_append_args(
                                         reply,
                                         DBUS_TYPE_STRING, &session->id,
                                         DBUS_TYPE_OBJECT_PATH, &p,
                                         DBUS_TYPE_STRING, &session->user->runtime_path,
                                         DBUS_TYPE_UNIX_FD, &fifo_fd,
+                                        DBUS_TYPE_STRING, &seat,
+                                        DBUS_TYPE_UINT32, &vtnr,
                                         DBUS_TYPE_INVALID);
                         free(p);