Commit Graph

1782 Commits

Author SHA1 Message Date
Jacek Caban 649be380b1 ntdll: Call send_debug_event from debug handler on x86_64.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-09-04 20:03:30 +02:00
Francois Gouget d504332b1c kernel32/tests: Avoid unneeded strlen*() calls.
Signed-off-by: Francois Gouget <fgouget@free.fr>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-09-04 17:11:29 +02:00
Jacek Caban 42a9b58b06 kernel32/tests: Add exception handling race test.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-27 21:53:03 +02:00
Alexandre Julliard 505be3a0a2 kernelbase: Implement SetThreadStackGuarantee().
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-24 11:39:07 +02:00
Jacek Caban 0f4ef1c3df kernel32/tests: Add single step and debug service tests.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-14 17:41:01 +02:00
Rémi Bernon d1a7b681ea ntdll: Change zero_bits parameter type to ULONG_PTR for NtMapViewOfSection and NtAllocateVirtualMemory.
It can be a pointer mask, eventually 64bit, and ULONG_PTR is what can be
found in several documentation of these functions.

Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 12:11:15 +02:00
Nikolay Sivov 2a15f77b49 ntdll: Ignore -1 time value same as 0 when setting file times.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-09 10:03:19 +02:00
Nikolay Sivov 70189853e2 kernel32/tests: Add some tests for setting file times.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-09 10:03:14 +02:00
Francois Gouget 8080e204bf kernel32/tests: A couple of spelling fixes in ok() call messages.
Signed-off-by: Francois Gouget <fgouget@free.fr>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-08 17:53:36 +02:00
Jacek Caban c1a32a080f server: Report only one debug event per process at the time.
Instead of one per thread.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-07 00:12:26 +02:00
Jacek Caban 6b46a4d24a kernel32/tests: Improve timeout handling in debugger tests.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-07 00:12:25 +02:00
André Hentschel 19d96f99c6 kernel32/tests: Don't test functions directly when reporting GetLastError().
Signed-off-by: André Hentschel <nerv@dawncrow.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-02 10:52:03 +02:00
Nikolay Sivov fdf8d7176f kernel32: Support FileBasicInfo case in SetFileInformationByHandle().
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-31 20:48:57 +02:00
Serge Gautherie 7e0acf14cc kernel32/tests: Test QueryFullProcessImageNameW() flags.
Signed-off-by: Serge Gautherie <winehq-git_serge_180711@gautherie.fr>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-31 09:28:38 +02:00
Jacek Caban 4ee629a3ba kernel32: Use DebugBreakProcess in DebugActiveProcess.
Fixes attaching to a process with VS remote debugger. It expects the
first break exception address to be DbgBreakPoint.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-05 17:42:25 +02:00
Jacek Caban dc3623f57f winternl.h: Remove inline DbgBreakPoint version.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-05 17:42:19 +02:00
Jacek Caban a679f965c8 kernel32: Reimplement DebugBreakProcess on top of DbgUiIssueRemoteBreakin.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-05 17:42:16 +02:00
Jacek Caban 4f1185d21e kernel32: Terminate process in unhandled exception handler.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-04 21:14:54 +02:00
Jacek Caban 3fded30a10 server: Fix debug event order in generate_startup_debug_events.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-04 21:14:54 +02:00
Jacek Caban 6aaa2b23a3 kernel32/tests: Add more debugger tests.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-04 21:14:54 +02:00
Fabian Maurer 6525a16673 ntdll: Check the activation context before looking for the module basename.
Signed-off-by: Fabian Maurer <dark.shadow4@web.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-24 10:50:53 +02:00
Alexandre Julliard 91bbc46c99 ntdll: Try to use the name of the PE file also when loading .so builtin.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-24 10:50:53 +02:00
Fabian Maurer aa97c30b01 kernel32/tests: Add sxs tests.
Signed-off-by: Fabian Maurer <dark.shadow4@web.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-24 10:50:53 +02:00
Rémi Bernon d1b7e01e5e ntdll/tests: Move NtMapViewOfSection tests from kernel32/tests.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-20 22:32:40 +02:00
Rémi Bernon d6bc3830e4 kernel32/tests: Fix some NtMapViewOfSection tests expectations, and add results for w1064v1809.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-20 22:32:05 +02:00
Huw Davies 2706b94dd0 kernel32/tests: Add a test for GetTickCount().
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-14 18:23:55 +02:00
Alexandre Julliard f59d05223d server: Fix the returned error code for an invalid NT header offset.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47359
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-13 20:55:35 +02:00
Rémi Bernon f39c1eee49 ntdll/tests: Move NtAllocateVirtualMemory tests that were in kernel32.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-11 18:18:39 +02:00
Rémi Bernon 4d5c874f42 kernel32/tests: Fix NtAllocateVirtualMemory tests results on w1064v1809.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-05 23:06:52 +02:00
Alexandre Julliard 0d9d816fc3 kernel32: Fix handling of LOAD_WITH_ALTERED_SEARCH_PATH when other search flags are specified.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=46809
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-05 21:40:55 +02:00
Sven Baars c340890146 kernel32/tests: Open and close the right file handle (Coverity).
Signed-off-by: Sven Baars <sven.wine@gmail.com>
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-27 14:39:14 +02:00
Michael Stefaniuc 260e66ee8b kernel32/tests: Use the ARRAY_SIZE() macro.
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-24 21:56:07 +02:00
Piotr Caban 4a6e69ad3a libwine: Ignore 0 weights as described in Unicode collation algorithm.
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-22 19:16:05 +02:00
Piotr Caban 40a1a9e9a2 libwine: Decompose characters before comparing in wine_compare_string.
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-22 19:16:05 +02:00
Piotr Caban 344057ef34 kernel32: Add more CompareStringW tests.
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-20 22:12:30 +02:00
Hans Leidekker 4872747b27 ntdll: Fix breakpoint exception address on 64-bit Linux.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-15 22:04:39 +02:00
Huw Davies 71dc2514c3 kernel32: Forward GetSystemTimeAsFileTime() to NtQuerySystemTime().
This relies on FILETIME and LARGE_INTEGER having the same layout.

On an i7-8700 CPU @ 3.20GHz with HZ=1000 it cuts the call cost from
~18ns to ~12ns.

Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-15 19:23:48 +02:00
Francois Gouget 6a20bb2daf kernel32/tests: Use ok_() so the TestBot can correctly detect the line.
Otherwise the messages appear to change every time the line count
changes, which making old errors new again.

Signed-off-by: Francois Gouget <fgouget@free.fr>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-09 08:20:38 -05:00
Erich E. Hoover 690a9003b3 kernel32: Add SearchPath test demonstrating the priority of the working directory.
Signed-off-by: Vijay Kiran Kamuju <infyquest@gmail.com>
Signed-off-by: Erich E. Hoover <erich.e.hoover@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-01 11:28:58 +02:00
Nikolay Sivov fe0f8a150f ntdll: Initialize critical section debug info with correct pointer value.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-30 20:08:04 +02:00
Jactry Zeng 642919382f kernel32/tests: Avoid a crash on WinXP and Win2K.
Signed-off-by: Jactry Zeng <jzeng@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-29 09:37:09 +02:00
Detlef Riekenberg f5636dea60 kernel32/pipe: Avoid a crash in a test.
Signed-off-by: Detlef Riekenberg <wine.dev@web.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-26 21:07:58 +02:00
Nikolay Sivov bf174815ba kernel32/tests: Add a test for critical section DebugInfo initial value.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-25 17:28:10 +02:00
Alexandre Julliard d4ef782db7 makefiles: Build all tests with msvcrt.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-24 12:10:51 +02:00
Fabian Maurer 28e6fe3782 kernel32: Stub FindFirstStreamW/FindNextStreamW.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=46934
Signed-off-by: Fabian Maurer <dark.shadow4@web.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-22 19:48:28 +02:00
Zhiyi Zhang 04ccd995b1 kernel32: Open replaced file without GENERIC_WRITE in ReplaceFileW().
As MSDN says, the replaced file is opened with the GENERIC_READ, DELETE,
and SYNCHRONIZE access rights. If GENERIC_WRITE is added, then it will
fail with previous file opens without FILE_SHARE_WRITE.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=33845
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-11 19:29:42 +02:00
Zhiyi Zhang 57e8e2d59c kernel32/tests: Add more tests for ReplaceFileA().
Also remove residue test files and remove no effect tests.

Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-11 19:29:42 +02:00
Zhiyi Zhang 304fb43aaa kernel32/tests: Test readonly file access.
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-11 19:29:42 +02:00
Detlef Riekenberg c26a3a0116 kernel32/tests: Fix FormatMessage test failures on recent win10 (ERROR_NO_WORK_DONE).
FormatMessageA/W sets last error to ERROR_NO_WORK_DONE when nothing
was done, after Sep 2015, but before or with Win10 v1709.

Signed-off-by: Detlef Riekenberg <wine.dev@web.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-05 22:16:31 +02:00
Alexandre Julliard 35d202fc09 kernel32: Validate handle before freeing a LOAD_LIBRARY_AS_DATAFILE module.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=46019
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-04-05 22:16:30 +02:00