The generic XaceHook() call isn't typesafe (und unnecessarily slow).
Better add an explicit function, just like we already have for others.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1556>
The generic XaceHook() call isn't typesafe (und unnecessarily slow).
Better add an explicit function, just like we already have for others.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1556>
The generic XaceHook() call isn't typesafe (und unnecessarily slow).
Better add an explicit function, just like we already have for others.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1556>
This could potentially be security related or crash the server:
XFixesSelectSelectionInput() calls the XACE_SELECTION_ACCESS hook with
wrong parameter type: XID instead of pointer to Selection struct.
It seems that it hadn't been kept up in XACE changed to polyinstantiation.
When XACE is used (eg. Security or SELinux extension enabled), this can
easily lead to memory corruptions at attacker-controlled locations, since
the client-given XID is interpreted as the memory location of Selection
structure.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1556>
The secur.h doesn't need the symbols defined here (eg. Status or Display)
anymore, so no need to keep it around anymore.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1550>
The comment about ClientPtr also being defined in misc.h is outdated
for about 20 years now: XFree86 4.3.0.1 dropped the redundant definition
over there.
It's still also in Xdefs.h, so the guard is still needed.
Fixes: d568221710
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1514>
This header isn't public and holds defines for code in os/ directory,
so no need to keep it in the global header dir - it's probably better
off in os/ directory - just like we already have with many others.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1389>
We're currently not checking whether IPv6 is available before build,
so it just gets silently disabled if AF_INET6 is missing - even
when user wants to enable it explicitly. Adding explicit check into
meson.build, so failing when ipv6 option enabled, but no IPv6 supported.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1539>
Conditional on ipv6 around including <arpa/inet.h> isn't necessary.
The only reason target not having it is win32, but it doesn't enable
SIOCGLIFCONF anyways.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1539>
The current implementation silently disables Xnest, even if requested
explcitly. That's a bit unstable behaviour - it's better to break the
build in those cases, just disable silently in auto mode.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1534>
No reason to explicitly force it off on Windows - if dependencies are present,
we can build it. Even though it will be rarely needed.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1534>
DES isn't considered secure anymore for long time now, more and more platforms
dropping DES from their RPC implementations, and even the one where it came
from (Solaris) disabled it for a decade now. We have much better alternatives
(eg. passing creds via Unix socket for local connections, ssh tunneling,
MIT-MAGIC-COOKIE-1, ...), so it's unlikely anybody still really relying on it.
Therefore, sweep it out.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1453>
Instead of keeping lots of special hacks for Solaris, just rename the
field of struct i386_segment_regs, so we don't need special care anymore.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1548>
The header exists on all supported platform, maybe some might still need
to define _XOPEN_SOURCE to get pow() defined.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1548>
All supported platforms, except Linux, have have to call xf86InitVidMem()
from xf86scanpci(), so we can make the code much simpler.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1548>
Since kdrive is only working on Unix'es, we don't need to care whether
that file might not exist on Windows, neither any need for doing so
exlusively on Solaris.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1548>
If a child window of the same size is unmapped, we should stop walking
the tree looking for the surface window to use.
Whatever lies beneath is not visible anyway.
This also fixes an issue with the Damage list becoming corrupted when
destroying a window, because the first thing that DeleteWindow() does
is to unmap the window and crush the window tree underneath it.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
Fixes: 3a0fc268 - xwayland: Add xwl_window::surface_window
Closes: https://gitlab.freedesktop.org/xorg/xserver/-/issues/1680
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1564>
Remove the previous change which ensured that the xwayland pkgconfig
file was installed into $libdir. This is a breaking change for build
systems searching for the xwayland pkg-config file. The sharedir
location fits xwayland better since the pkg-config file does not contain
linking information, it only contains the data on how to locate the
xwayland binary and which features are enabled.
Signed-off-by: Rouven Czerwinski <rouven@czerwinskis.de>
Reviewed-by: Olivier Fourdan <ofourdan@redhat.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1543>
Before this change, the xwayland pkgconfig file will always contain an
includedir directive, even though xwayland is not a linkable shared
library:
prefix=/nix/store/3spcjqp5zcyg8arz6dnsj59fal5yk3jy-xwayland-23.2.6
includedir=${prefix}/include
exec_prefix=${prefix}
xwayland=/nix/store/3spcjqp5zcyg8arz6dnsj59fal5yk3jy-xwayland-23.2.6/bin/Xwayland
[…]
Cflags: -I${includedir}
According to a bug reporter this trips up cmake [1], which expects that
the include directory exists, which it does not since xwayland does not
install any header files.
Add the dataonly directive to pkgsconfig.generate() which will remove
the default "." subdir and ensures that includedir is not set inside the
pkgconfig file. Additionally enforce the install directory to
$libdir/pkgconfig, since it otherwise will be installed to
$datadir/pkgconfig, which precludes programs from finding the pkgconfig
because share/pkgconfig is usually not included in the search path.
The resulting pkgconfig does not contain an includedir:
prefix=/nix/store/p7xhdzl65hfhzf36vxykzp2i9cyy7y6c-xwayland-23.2.6
exec_prefix=${prefix}
xwayland=/nix/store/p7xhdzl65hfhzf36vxykzp2i9cyy7y6c-xwayland-23.2.6/bin/Xwayland
have_glamor=true
have_eglstream=true
have_initfd=true
have_listenfd=true
have_verbose=true
have_terminate_delay=true
have_no_touch_pointer_emulation=true
have_force_xrandr_emulation=true
have_geometry=true
have_fullscreen=true
have_host_grab=true
have_decorate=false
have_enable_ei_portal=true
have_byteswappedclients=true
Name: Xwayland
Description: X Server for Wayland
Version: 23.2.6
[1]: https://github.com/NixOS/nixpkgs/pull/309075#issuecomment-2108381428
Signed-off-by: Rouven Czerwinski <rouven@czerwinskis.de>
Reviewed-by: Olivier Fourdan <ofourdan@redhat.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1543>
The last use of struct '_SrvXkmInfo' was removed in
commit fbd7768946 ("XKB: Ditch XkbFileInfo").
Remove it.
The define MAX_TOC hasn't been used in this file since sometime
in the mid 90's; it's unused in version '1997/05/20 11:42:06'
but in '1.8 94/05/16 10:49:53' it's used in the definition
of _SrvXkmInfo.
Remove it.
Build tested.
Signed-off-by: Dr. David Alan Gilbert <dave@treblig.org>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1558>
The core keyboard before this change always used a layout of "us" even if you
configured the build with another default layout.
Signed-off-by: Michael Dluhosch <michael.dluhosch@gmail.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1549>
The sun_apm.c support was written to a draft version of the interfaces that
were integrated under a different name (SRN - Suspend/Resume Notification)
in 2007 for OpenSolaris, and what eventually became Solaris 11.0. Adopt the
official names and use the system-provided header file for these now.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1540>
Left over from the builtin keyboard driver removed from the Xorg
server in 2006 (commit 3eeb62e8f5).
Requires xorg/driver/xf86-input-keyboard@40ef7d9e24987eb6708d822d0ea070
to build the current keyboard driver with this change.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1541>
This restores the handling of the XRandR emulation for Xwayland rootless
where it was before commit fa7b1c20.
Some compositors may trigger a protocol error if the viewport source is
larger than the actual window size, having that handled in the window
resize hook makes sure we do not regress.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1521>