Commit Graph

7 Commits

Author SHA1 Message Date
Gyorgy Sarvari 4417646cda waitforx: remove unneded header
The sys/signal.h is essentially a redirect to signal.h, without further
logic. However when using musl libc, a warning (which is treated as an error)
is also emitted about this:

| /usr/include/sys/signal.h:1:2: error: #warning redirecting incorrect #include <sys/signal.h> to <signal.h> [-Werror=cpp]
|     1 | #warning redirecting incorrect #include <sys/signal.h> to <signal.h>

Remove sys/signal.h header to solve the problem - the signal.h header is already
included in this file.

Signed-off-by: Gyorgy Sarvari <skandigraun@gmail.com>
2025-11-25 15:43:38 +01:00
firewave 67c11f0443 mitigated -Wdocumentation and -Wdocumentation-unknown-command Clang compiler warnings 2025-11-04 13:40:33 +01:00
matt335672 2a190a2264 Fix regression in opening local display in waitforx
Commit 80fab03198 introduced a way to
prevent waitforx going to the network when trying to open a display,
and hence potentially blocking.

This method turned out to be invalidated by libxcb version 1.16 and
1.17

This change adds an explicit check that the Unix socket for the display
in /tmp/.X11-unix/Xn is open before trying to connect to display ':n'.
This has the same effect.
2024-12-11 11:52:06 +00:00
matt335672 80fab03198 waitforx changes
1) Changed alarm message from "Timed out waiting for RandR outputs" to
   "Timed out waiting for X display". The former was confusing, and the
   times where this message was triggered were nothing to do with
   RandR
2) Don't try to open a display of the form ":n" or ":n.m" directly
   (n,m >= 0). If the X server hasn't yet opened its local socket,
   the XOpenDisplay() call can go to the network and possibly block
   for a long time. Instead, use the (undocumented) "unix:n" display
   specification, whih never goes to the network, and doesn't block.
2024-11-27 10:28:04 +00:00
matt335672 5c01729d6f waitforx logging improvements 2023-03-18 10:54:14 +00:00
Derek Schrock cb39b84de5 Use g_set_alarm and g_sleep 2023-02-11 18:01:12 -05:00
Derek Schrock 829378bba8 Add xrdp-waitforx to wait for X to start with RandR outputs
For some window managers (fvwm2 and fvwm3) if the X server isn't
running and has output it's possible for the window manager to fail or
reconfigure randr incorrectly.

With xrdp-waitfox:
 - Install xrdp-waitfox to the BIN dir.
 - sesman will run xrdp-waitfox as the logged in user.
 - Set an alarm to exit after 30 seconds.
 - Try to open env DISPLAY value's display (10 seconds).
 - Test for RandR extension.
 - Wait for outputs to appear (10 seconds).
2023-02-11 18:01:10 -05:00