In rare cases we get an event during the second iteration of the loop,
changing the first element. This would lead to an assertion later.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=55054
Which may be different from the last desktop cursor handle.
This makes the behavior better match the old winex11 behavior, which queried
the current thread input cursor handle on every mouse move to sync it with X11,
although it contradicts MSDN documentation which states that the cursor handle
is global.
This fixes the X11 cursor being visible in "Deus Ex: GOTY Edition".
This brings getpeername() in line with getsockname(), which
is also implemented in wineserver. It also allows getpeername()
to return a possibly-more-accurate peer name, as in the case of
AF_UNIX sockets.
I have an application that creates its special registry key using
NtCreateKey(parent, "Something\0"), and then expects to be able to
open this key with NtOpenKey("Something\0") on start up. Currently
this fails because terminating '\0' in the key name doesn't survive
saving/loading the registry. parse_strW() helper already supports
loading such key names.
As the tests show after creating a kernel object with the name "Something\0"
it's possible to only open it as "Something\0", and an attempt opening it
as "Something" fails with STATUS_OBJECT_NAME_NOT_FOUND, and vice versa.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
We were using bit 1 of RTL_USER_PROCESS_PARAMETERS for two different cases:
- rightfully, as a sign to block ctrl-c events from being processed by
handlers (and by default, terminating the process)
- But this was also used to request for the creation of a new process group.
This patch properly separates the two use cases, by using the
ProcessGroupId field in RTL_USER_PROCESS_PARAMETERS (checked that Win10
behaves as this patch in RtlCreateUserProcess wrt.
RTL_USER_PROCESS_PARAMETERS ProcessGroupId usage input/output).
Introduce process_group_id in startup_info_t and use it to pass it to
server. ProcessGroupId field in RTL_USER_PROCESS_PARAMETERS is now properly
set.
Note: this will change some external behavior.
- before this patch, a child process created with Ctrl-C disabled
(ConsoleFlags set), couldn't turn it on as the process was detached
from unix console.
- now, SIGINT handling is moved to kernelbase (and can be turned on/off at
application will),
- when creating a new windows group id, the child will be detached from
unix console, so will no longer receives the SIGINT from ctrl-c in unix
console (if parent was attached to this unix console).
Signed-off-by: Eric Pouech <epouech@codeweavers.com>
musl libc doesn't supply any definitions for IPX, such as the SOL_IPX
macro. However, it still provides linux/ipx.h from Linux uAPI header
files if it exists.
Linux kernel wouldn't drop linux/ipx.h from uAPI headers until 5.15,
although IPX support has already been marked obsolete since 2018.
Fix this by not defining HAS_IPX if linux/ipx.h has been included but
nothing defines the SOL_IPX macro.
Status of IPX support from other libcs are noted below:
- bionic: netipx/ipx.h does not exist. linux/ipx.h may or may not
exist. Note that sys/socket.h defines SOL_IPX even if linux/ipx.h is
missing.
- glibc: netipx/ipx.h exists. In this case, Wine assumes IPX support
even if the operating system does not support it in runtime.
- BSD variants: netipx/ipx.h may or may not exist. linux/ipx.h does not
exist. Some BSDs supply SO_DEFAULT_HEADERS instead of SOL_IPX.
Fixes: 41cc117b3f