chiark / gitweb /
logind: implement D-Bus properties
[elogind.git] / src / logind-device.c
index 4e076c20b63c7728e278aca8d31457cc69c3b35c..31afa4ff2a776cb420bda0ca119142b877654b9f 100644 (file)
@@ -80,6 +80,6 @@ void device_attach(Device *d, Seat *s) {
         if (d->seat)
                 device_detach(d);
 
-        LIST_PREPEND(Device, devices, d->seat->devices, d);
         d->seat = s;
+        LIST_PREPEND(Device, devices, s->devices, d);
 }