Age | Commit message (Collapse) | Author |
|
Dispatch on IPC call only dispatched until the first message was
successfully processed. This could lead to premature dispatch
termination if a background event was received during an IPC call.
Instead, continue dispatching until a non-bg opcode is reported or an
error is received.
|
|
|
|
|
|
Only if a device had an fd and was active would an fd be closed. As
devices are deactivated early on session switch, this lead to fd
leakage.
Close fds regardless of active state.
|
|
The seat activation logic did not correctly handle VT switching and
switching between multiple sessions.
Session switching on VT-bound seats is now performed using a VT switch,
taking advantage of VT signals to perform the actual switch. This
simplifies switching logic and makes it more robust.
|
|
|
|
Signal handling relied on poll(2) being interrupted by signals, followed
by a check for signal handlers flagging a signal as received. This only
allowed signals that were received during poll(2) to be handled
correctly.
Implement the usual self-pipe implementation, where signal handlers
write an arbitrary byte to a polled file descriptor to ensure proper
level-triggered signal handling.
|
|
|
|
|
|
|
|
The connection buffer position was erroneously rewinded before reading
the protocol message when the message was a SERVER_ERROR.
|
|
We want to use the scdoc of the host system not the target system, so
pass the `native: true` parameter to meson.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
test_run and test_assert replaces regular assert with better logging
which include the currently running test name. The tests can now also be
built without DEBUG.
|
|
|
|
|
|
|
|
|
|
|
|
Silences a warning on some architectures.
|
|
|
|
|
|
|
|
|
|
The content of this message is unused, so it should be converted to a
content-less message.
|
|
|
|
|
|
Store if an error has occurred and return -1 with ENOTCONN from all
future calls, avoiding attempts to use a broken connection.
|
|
Add helpers around connection access to have all logging centralized and
reduce code duplication. Improve existing helpers to further reduce code
duplication.
The seatd backend should have much better logging after this.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
FreeBSD TTY paths are contructed in the kernel using the %r formatter,
which in this case ends up being a base 32 encoding.
The base 32 implementation is taken more or less directly from wlroots
commit fc6c0ca12e94.
|
|
This was causing all VT and TTY changes to be applied to the wrong TTY.
|
|
Taken from X11, weston and consolekit2 ports for FreeBSD.
Setting just K_CODE as done before makes input seemingly have no ill
effects, but it is still buffered and possibly send to the terminal
after application exit if stdin is never drained. Setting raw mode
appears to be needed to solve that issue.
A K_OFF-like VT keyboard setting like Linux has would seem more
appropriate, but that is not currently available to us on FreeBSD.
|
|
|
|
The default level is SILENT. log_init no longer takes an initial log
level (so that calls to libseat_set_log_level prior to log_init work
correctly).
|
|
This will be replaced with a libseat API to set the log level.
|
|
This allows libseat users to register a custom logging function.
|
|
This is preparatory work for exposing a public function to set libseat's
log handler.
|
|
The logind code is based on the wlroots implementation, which in turn
contained copy-paste code from Mutter that serves no purpose here.
|