aboutsummaryrefslogtreecommitdiff
path: root/libseat/backend/logind.c
AgeCommit message (Collapse)Author
2021-09-22logind: Improve error handling in open_seatKenny Levinsen
errno was not being set by open_seat in most cases, leading to simpletest possibly failing with "libseat_open_seat() failed: Success".
2021-09-22logind: check if session is active on startupSimon Ser
Up until now we assumed the session was always active on startup. This might not be the case. Instead, read the current value of the Active property.
2021-09-21logind: Send ping to wake us up laterKenny Levinsen
sd_bus_call drains received messages into the receive queue, and peeks for its own return value. It does not dispatch the receive queue. As the socket is drained, the caller will not wake from a poll and have no reason to dispatch libseat. This has gone unnoticed largely due to logind sending an event for every device, making it unlikely that no unread message will be left on the socket. Like we have done for seatd, we fix this by sending a "ping" request to logind if anything is left in our receive queue as reported by sd_bus_get_events. The response to this will wake us up and ensure that dispatch is called.
2021-08-15logind: Remove redundant null checkKenny Levinsen
2021-08-15Make libseat_seat_listener constSimon Ser
libseat will never write to that struct. Let's allow callers to make it read-only.
2021-07-09libseat: Rename dispatch_background in backendsKenny Levinsen
This name never made much sense. dispatch_and_execute is more meaningful, especially when compared to the non-executing dispatch function.
2021-02-27logind: Fix return values from close_device/get_fdKenny Levinsen
2020-12-23logind: Send ReleaseControl when closing seatKenny Levinsen
This is not strictly speaking necessary as detaching from the bus should trigger this automatically, but elogind apparently has issues with this. Doing this explicitly does no harm, so let's just do that.
2020-12-04libseat/backend/logind: stop waiting for CanGraphicalSimon Ser
Upstream says compositors should wait for DRM nodes using udev instead.
2020-11-24logind: switch_session should return 0 on successKenny Levinsen
It currently returned -1 on failure and 1 on success. The API is intended to return -1 on failure and 0 on success, so fix that.
2020-10-11logind: clang-formatKenny Levinsen
2020-10-10logind: Use seat_path for SwitchToKenny Levinsen
2020-09-28logind: close_device should not close fdKenny Levinsen
2020-08-28logind: Merge PropertiesChanged handlersKenny Levinsen
2020-08-28libseat: Expand logging in all backendsKenny Levinsen
2020-08-24libseat: Remove useless logind fallbacksKenny Levinsen
The logind code is based on the wlroots implementation, which in turn contained copy-paste code from Mutter that serves no purpose here.
2020-08-23logind: Set session type from envKenny Levinsen
2020-08-23logind: Remove session type checkKenny Levinsen
2020-08-23logind: Remove useless checkKenny Levinsen
2020-08-06logind: Allow SwitchTo for all seatsKenny Levinsen
2020-08-06logind: close_device always returned errorKenny Levinsen
Error handling was broken in close_device, always returning -1. Use the return value, and add a few errno assignments while we're at it.
2020-08-05libseat: Rename libseat_impl to seat_implKenny Levinsen
2020-08-03libseat: Convert clients to linked_listKenny Levinsen
2020-07-31Initial implementation of seatd and libseatKenny Levinsen