Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
8a169390
Commit
8a169390
authored
Jun 30, 2020
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Build with msvcrt.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
f89f7a54
Show whitespace changes
Inline
Side-by-side
Showing
45 changed files
with
77 additions
and
249 deletions
+77
-249
loader.c
dlls/kernel32/tests/loader.c
+14
-12
Makefile.in
dlls/ntdll/Makefile.in
+2
-2
actctx.c
dlls/ntdll/actctx.c
+0
-3
atom.c
dlls/ntdll/atom.c
+0
-3
critsection.c
dlls/ntdll/critsection.c
+0
-3
debugbuffer.c
dlls/ntdll/debugbuffer.c
+0
-3
directory.c
dlls/ntdll/directory.c
+0
-3
env.c
dlls/ntdll/env.c
+0
-11
error.c
dlls/ntdll/error.c
+0
-2
exception.c
dlls/ntdll/exception.c
+11
-3
file.c
dlls/ntdll/file.c
+0
-3
heap.c
dlls/ntdll/heap.c
+2
-8
large_int.c
dlls/ntdll/large_int.c
+5
-8
loader.c
dlls/ntdll/loader.c
+5
-10
loadorder.c
dlls/ntdll/loadorder.c
+1
-4
locale.c
dlls/ntdll/locale.c
+1
-14
misc.c
dlls/ntdll/misc.c
+3
-6
nt.c
dlls/ntdll/nt.c
+0
-3
ntdll.spec
dlls/ntdll/ntdll.spec
+7
-7
ntdll_misc.h
dlls/ntdll/ntdll_misc.h
+0
-5
om.c
dlls/ntdll/om.c
+0
-5
path.c
dlls/ntdll/path.c
+0
-4
printf.c
dlls/ntdll/printf.c
+12
-15
process.c
dlls/ntdll/process.c
+0
-3
reg.c
dlls/ntdll/reg.c
+0
-4
relay.c
dlls/ntdll/relay.c
+0
-3
resource.c
dlls/ntdll/resource.c
+0
-3
rtl.c
dlls/ntdll/rtl.c
+4
-13
rtlbitmap.c
dlls/ntdll/rtlbitmap.c
+1
-1
rtlstr.c
dlls/ntdll/rtlstr.c
+0
-2
sec.c
dlls/ntdll/sec.c
+0
-7
server.c
dlls/ntdll/server.c
+0
-3
signal_arm.c
dlls/ntdll/signal_arm.c
+0
-3
signal_arm64.c
dlls/ntdll/signal_arm64.c
+0
-6
signal_i386.c
dlls/ntdll/signal_i386.c
+0
-9
signal_x86_64.c
dlls/ntdll/signal_x86_64.c
+0
-3
string.c
dlls/ntdll/string.c
+6
-15
sync.c
dlls/ntdll/sync.c
+0
-3
thread.c
dlls/ntdll/thread.c
+0
-3
threadpool.c
dlls/ntdll/threadpool.c
+0
-3
time.c
dlls/ntdll/time.c
+0
-6
loader.c
dlls/ntdll/unix/loader.c
+0
-1
version.c
dlls/ntdll/version.c
+0
-3
virtual.c
dlls/ntdll/virtual.c
+0
-7
wcstring.c
dlls/ntdll/wcstring.c
+3
-11
No files found.
dlls/kernel32/tests/loader.c
View file @
8a169390
...
@@ -3901,7 +3901,7 @@ static void test_wow64_redirection(void)
...
@@ -3901,7 +3901,7 @@ static void test_wow64_redirection(void)
ok
(
pWow64RevertWow64FsRedirection
(
OldValue
),
"Re-enabling FS redirection failed
\n
"
);
ok
(
pWow64RevertWow64FsRedirection
(
OldValue
),
"Re-enabling FS redirection failed
\n
"
);
}
}
static
void
test_dll_file
(
const
char
*
name
)
static
void
test_dll_file
(
const
char
*
name
,
BOOL
is_todo
)
{
{
HMODULE
module
=
GetModuleHandleA
(
name
);
HMODULE
module
=
GetModuleHandleA
(
name
);
IMAGE_NT_HEADERS
*
nt
,
*
nt_file
;
IMAGE_NT_HEADERS
*
nt
,
*
nt_file
;
...
@@ -3926,27 +3926,29 @@ static void test_dll_file( const char *name )
...
@@ -3926,27 +3926,29 @@ static void test_dll_file( const char *name )
nt_file
=
pRtlImageNtHeader
(
ptr
);
nt_file
=
pRtlImageNtHeader
(
ptr
);
ok
(
nt_file
!=
NULL
,
"%s: invalid header
\n
"
,
path
);
ok
(
nt_file
!=
NULL
,
"%s: invalid header
\n
"
,
path
);
#define OK_FIELD(x) ok( nt->x == nt_file->x, "%s:%u: wrong " #x " %x / %x\n", name, i, nt->x, nt_file->x )
#define OK_FIELD(x) ok( nt->x == nt_file->x, "%s:%u: wrong " #x " %x / %x\n", name, i, nt->x, nt_file->x )
todo_wine
todo_wine
_if
(
is_todo
)
OK_FIELD
(
FileHeader
.
NumberOfSections
);
OK_FIELD
(
FileHeader
.
NumberOfSections
);
todo_wine
todo_wine
_if
(
is_todo
)
OK_FIELD
(
OptionalHeader
.
AddressOfEntryPoint
);
OK_FIELD
(
OptionalHeader
.
AddressOfEntryPoint
);
OK_FIELD
(
OptionalHeader
.
NumberOfRvaAndSizes
);
OK_FIELD
(
OptionalHeader
.
NumberOfRvaAndSizes
);
for
(
i
=
0
;
i
<
nt
->
OptionalHeader
.
NumberOfRvaAndSizes
;
i
++
)
for
(
i
=
0
;
i
<
nt
->
OptionalHeader
.
NumberOfRvaAndSizes
;
i
++
)
{
{
todo_wine_if
(
i
==
IMAGE_DIRECTORY_ENTRY_EXPORT
||
todo_wine_if
(
is_todo
&&
(
i
==
IMAGE_DIRECTORY_ENTRY_EXPORT
||
(
i
==
IMAGE_DIRECTORY_ENTRY_IMPORT
&&
nt
->
OptionalHeader
.
DataDirectory
[
i
].
Size
)
||
(
i
==
IMAGE_DIRECTORY_ENTRY_IMPORT
&&
nt
->
OptionalHeader
.
DataDirectory
[
i
].
Size
)
||
i
==
IMAGE_DIRECTORY_ENTRY_RESOURCE
||
i
==
IMAGE_DIRECTORY_ENTRY_RESOURCE
||
i
==
IMAGE_DIRECTORY_ENTRY_BASERELOC
)
i
==
IMAGE_DIRECTORY_ENTRY_BASERELOC
)
)
OK_FIELD
(
OptionalHeader
.
DataDirectory
[
i
].
VirtualAddress
);
OK_FIELD
(
OptionalHeader
.
DataDirectory
[
i
].
VirtualAddress
);
todo_wine_if
(
i
==
IMAGE_DIRECTORY_ENTRY_EXPORT
||
todo_wine_if
(
is_todo
&&
(
i
==
IMAGE_DIRECTORY_ENTRY_EXPORT
||
(
i
==
IMAGE_DIRECTORY_ENTRY_IMPORT
&&
nt
->
OptionalHeader
.
DataDirectory
[
i
].
Size
)
||
(
i
==
IMAGE_DIRECTORY_ENTRY_IMPORT
&&
nt
->
OptionalHeader
.
DataDirectory
[
i
].
Size
)
||
i
==
IMAGE_DIRECTORY_ENTRY_BASERELOC
)
i
==
IMAGE_DIRECTORY_ENTRY_BASERELOC
)
)
OK_FIELD
(
OptionalHeader
.
DataDirectory
[
i
].
Size
);
OK_FIELD
(
OptionalHeader
.
DataDirectory
[
i
].
Size
);
}
}
sec
=
(
IMAGE_SECTION_HEADER
*
)((
char
*
)
&
nt
->
OptionalHeader
+
nt
->
FileHeader
.
SizeOfOptionalHeader
);
sec
=
(
IMAGE_SECTION_HEADER
*
)((
char
*
)
&
nt
->
OptionalHeader
+
nt
->
FileHeader
.
SizeOfOptionalHeader
);
sec_file
=
(
IMAGE_SECTION_HEADER
*
)((
char
*
)
&
nt_file
->
OptionalHeader
+
nt_file
->
FileHeader
.
SizeOfOptionalHeader
);
sec_file
=
(
IMAGE_SECTION_HEADER
*
)((
char
*
)
&
nt_file
->
OptionalHeader
+
nt_file
->
FileHeader
.
SizeOfOptionalHeader
);
for
(
i
=
0
;
i
<
nt
->
FileHeader
.
NumberOfSections
;
i
++
)
for
(
i
=
0
;
i
<
nt
->
FileHeader
.
NumberOfSections
;
i
++
)
todo_wine
todo_wine
_if
(
is_todo
)
ok
(
!
memcmp
(
sec
+
i
,
sec_file
+
i
,
sizeof
(
*
sec
)
),
"%s: wrong section %d
\n
"
,
name
,
i
);
ok
(
!
memcmp
(
sec
+
i
,
sec_file
+
i
,
sizeof
(
*
sec
)
),
"%s: wrong section %d
\n
"
,
name
,
i
);
UnmapViewOfFile
(
ptr
);
UnmapViewOfFile
(
ptr
);
#undef OK_FIELD
#undef OK_FIELD
...
@@ -4040,10 +4042,10 @@ START_TEST(loader)
...
@@ -4040,10 +4042,10 @@ START_TEST(loader)
test_InMemoryOrderModuleList
();
test_InMemoryOrderModuleList
();
test_LoadPackagedLibrary
();
test_LoadPackagedLibrary
();
test_wow64_redirection
();
test_wow64_redirection
();
test_dll_file
(
"ntdll.dll"
);
test_dll_file
(
"ntdll.dll"
,
FALSE
);
test_dll_file
(
"kernel32.dll"
);
test_dll_file
(
"kernel32.dll"
,
TRUE
);
test_dll_file
(
"advapi32.dll"
);
test_dll_file
(
"advapi32.dll"
,
TRUE
);
test_dll_file
(
"user32.dll"
);
test_dll_file
(
"user32.dll"
,
TRUE
);
/* loader test must be last, it can corrupt the internal loader state on Windows */
/* loader test must be last, it can corrupt the internal loader state on Windows */
test_Loader
();
test_Loader
();
}
}
dlls/ntdll/Makefile.in
View file @
8a169390
EXTRADEFS
=
-D_NTSYSTEM_
EXTRADEFS
=
-D_NTSYSTEM_
-D_ACRTIMP
=
MODULE
=
ntdll.dll
MODULE
=
ntdll.dll
IMPORTLIB
=
ntdll
IMPORTLIB
=
ntdll
IMPORTS
=
winecrt0
IMPORTS
=
winecrt0
EXTRAINCL
=
$(UNWIND_CFLAGS)
EXTRAINCL
=
$(UNWIND_CFLAGS)
EXTRALIBS
=
-lwine
$(IOKIT_LIBS)
$(COREFOUNDATION_LIBS)
$(CORESERVICES_LIBS)
$(RT_LIBS)
$(PTHREAD_LIBS)
$(UNWIND_LIBS)
$(I386_LIBS)
EXTRALIBS
=
-lwine
$(IOKIT_LIBS)
$(COREFOUNDATION_LIBS)
$(CORESERVICES_LIBS)
$(RT_LIBS)
$(PTHREAD_LIBS)
$(UNWIND_LIBS)
$(I386_LIBS)
EXTRADLLFLAGS
=
-nodefaultlibs
-Wl
,--image-base,0x7bc00000
EXTRADLLFLAGS
=
-
mno-cygwin
-
nodefaultlibs
-Wl
,--image-base,0x7bc00000
C_SRCS
=
\
C_SRCS
=
\
actctx.c
\
actctx.c
\
...
...
dlls/ntdll/actctx.c
View file @
8a169390
...
@@ -22,9 +22,6 @@
...
@@ -22,9 +22,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
...
...
dlls/ntdll/atom.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdlib.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
...
...
dlls/ntdll/critsection.c
View file @
8a169390
...
@@ -18,9 +18,6 @@
...
@@ -18,9 +18,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <errno.h>
#include <errno.h>
#include <stdarg.h>
#include <stdarg.h>
...
...
dlls/ntdll/debugbuffer.c
View file @
8a169390
...
@@ -18,9 +18,6 @@
...
@@ -18,9 +18,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdlib.h>
#include <string.h>
#include <string.h>
...
...
dlls/ntdll/directory.c
View file @
8a169390
...
@@ -20,9 +20,6 @@
...
@@ -20,9 +20,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <sys/types.h>
#include <sys/types.h>
#include <fcntl.h>
#include <fcntl.h>
...
...
dlls/ntdll/env.c
View file @
8a169390
...
@@ -18,21 +18,10 @@
...
@@ -18,21 +18,10 @@
* License along with this library; if not, write to the Free Software
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include <assert.h>
#include <assert.h>
#include <errno.h>
#include <stdarg.h>
#include <stdarg.h>
#include <sys/types.h>
#include <sys/types.h>
#ifdef HAVE_SYS_STAT_H
# include <sys/stat.h>
#endif
#ifdef HAVE_PWD_H
# include <pwd.h>
#endif
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#include "ntstatus.h"
#include "ntstatus.h"
#define WIN32_NO_STATUS
#define WIN32_NO_STATUS
...
...
dlls/ntdll/error.c
View file @
8a169390
...
@@ -20,8 +20,6 @@
...
@@ -20,8 +20,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include "ntstatus.h"
#include "ntstatus.h"
...
...
dlls/ntdll/exception.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <errno.h>
#include <errno.h>
#include <signal.h>
#include <signal.h>
...
@@ -581,6 +578,17 @@ PRUNTIME_FUNCTION WINAPI RtlLookupFunctionEntry( ULONG_PTR pc, ULONG_PTR *base,
...
@@ -581,6 +578,17 @@ PRUNTIME_FUNCTION WINAPI RtlLookupFunctionEntry( ULONG_PTR pc, ULONG_PTR *base,
#endif
/* __x86_64__ || __arm__ || __aarch64__ */
#endif
/* __x86_64__ || __arm__ || __aarch64__ */
/*************************************************************
* _assert
*/
void
__cdecl
_assert
(
const
char
*
str
,
const
char
*
file
,
unsigned
int
line
)
{
ERR
(
"%s:%u: Assertion failed %s
\n
"
,
file
,
line
,
debugstr_a
(
str
)
);
RtlRaiseStatus
(
EXCEPTION_WINE_ASSERTION
);
}
/*************************************************************
/*************************************************************
* __wine_spec_unimplemented_stub
* __wine_spec_unimplemented_stub
*
*
...
...
dlls/ntdll/file.c
View file @
8a169390
...
@@ -16,9 +16,6 @@
...
@@ -16,9 +16,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdlib.h>
#include <stdlib.h>
#include <string.h>
#include <string.h>
#include <stdio.h>
#include <stdio.h>
...
...
dlls/ntdll/heap.c
View file @
8a169390
...
@@ -19,19 +19,13 @@
...
@@ -19,19 +19,13 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <stdlib.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
#include <string.h>
#include <string.h>
#ifdef HAVE_VALGRIND_MEMCHECK_H
#include <valgrind/memcheck.h>
#define RUNNING_ON_VALGRIND 0
/* FIXME */
#else
#define RUNNING_ON_VALGRIND 0
#endif
#include "ntstatus.h"
#include "ntstatus.h"
#define WIN32_NO_STATUS
#define WIN32_NO_STATUS
...
...
dlls/ntdll/large_int.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include "ntstatus.h"
#include "ntstatus.h"
...
@@ -547,11 +544,11 @@ NTSTATUS WINAPI RtlInt64ToUnicodeString(
...
@@ -547,11 +544,11 @@ NTSTATUS WINAPI RtlInt64ToUnicodeString(
/* those builtin functions use stdcall calling convention, but compilers reference them without stdcall declarations */
/* those builtin functions use stdcall calling convention, but compilers reference them without stdcall declarations */
#if defined(__MINGW32__) || defined(_MSC_VER)
#if defined(__MINGW32__) || defined(_MSC_VER)
LONGLONG
WINAPI
_alldiv
(
LONGLONG
a
,
LONGLONG
b
)
asm
(
"_alldiv"
);
LONGLONG
WINAPI
_alldiv
(
LONGLONG
a
,
LONGLONG
b
)
asm
(
__ASM_NAME
(
"_alldiv"
)
);
LONGLONG
WINAPI
_allmul
(
LONGLONG
a
,
LONGLONG
b
)
asm
(
"_allmul"
);
LONGLONG
WINAPI
_allmul
(
LONGLONG
a
,
LONGLONG
b
)
asm
(
__ASM_NAME
(
"_allmul"
)
);
LONGLONG
WINAPI
_allrem
(
LONGLONG
a
,
LONGLONG
b
)
asm
(
"_allrem"
);
LONGLONG
WINAPI
_allrem
(
LONGLONG
a
,
LONGLONG
b
)
asm
(
__ASM_NAME
(
"_allrem"
)
);
ULONGLONG
WINAPI
_aulldiv
(
ULONGLONG
a
,
ULONGLONG
b
)
asm
(
"_aulldiv"
);
ULONGLONG
WINAPI
_aulldiv
(
ULONGLONG
a
,
ULONGLONG
b
)
asm
(
__ASM_NAME
(
"_aulldiv"
)
);
ULONGLONG
WINAPI
_aullrem
(
ULONGLONG
a
,
ULONGLONG
b
)
asm
(
"_aullrem"
);
ULONGLONG
WINAPI
_aullrem
(
ULONGLONG
a
,
ULONGLONG
b
)
asm
(
__ASM_NAME
(
"_aullrem"
)
);
#endif
#endif
static
ULONGLONG
udivmod
(
ULONGLONG
a
,
ULONGLONG
b
,
ULONGLONG
*
rem
)
static
ULONGLONG
udivmod
(
ULONGLONG
a
,
ULONGLONG
b
,
ULONGLONG
*
rem
)
...
...
dlls/ntdll/loader.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <stdarg.h>
#include <stdarg.h>
...
@@ -1005,9 +1002,8 @@ static SHORT alloc_tls_slot( LDR_DATA_TABLE_ENTRY *mod )
...
@@ -1005,9 +1002,8 @@ static SHORT alloc_tls_slot( LDR_DATA_TABLE_ENTRY *mod )
if
(
!
new
)
return
-
1
;
if
(
!
new
)
return
-
1
;
if
(
old
)
memcpy
(
new
,
old
,
tls_module_count
*
sizeof
(
*
new
)
);
if
(
old
)
memcpy
(
new
,
old
,
tls_module_count
*
sizeof
(
*
new
)
);
teb
->
ThreadLocalStoragePointer
=
new
;
teb
->
ThreadLocalStoragePointer
=
new
;
#if defined(__APPLE__) && defined(__x86_64__)
#ifdef __x86_64__
/* macOS-specific hack */
if
(
teb
->
Reserved5
[
0
])
if
(
teb
->
Reserved5
[
0
])
((
TEB
*
)
teb
->
Reserved5
[
0
])
->
ThreadLocalStoragePointer
=
new
;
((
TEB
*
)
teb
->
Reserved5
[
0
])
->
ThreadLocalStoragePointer
=
new
;
#endif
#endif
TRACE
(
"thread %04lx tls block %p -> %p
\n
"
,
(
ULONG_PTR
)
teb
->
ClientId
.
UniqueThread
,
old
,
new
);
TRACE
(
"thread %04lx tls block %p -> %p
\n
"
,
(
ULONG_PTR
)
teb
->
ClientId
.
UniqueThread
,
old
,
new
);
/* FIXME: can't free old block here, should be freed at thread exit */
/* FIXME: can't free old block here, should be freed at thread exit */
...
@@ -1251,10 +1247,9 @@ static NTSTATUS alloc_thread_tls(void)
...
@@ -1251,10 +1247,9 @@ static NTSTATUS alloc_thread_tls(void)
GetCurrentThreadId
(),
i
,
size
,
dir
->
SizeOfZeroFill
,
pointers
[
i
]
);
GetCurrentThreadId
(),
i
,
size
,
dir
->
SizeOfZeroFill
,
pointers
[
i
]
);
}
}
NtCurrentTeb
()
->
ThreadLocalStoragePointer
=
pointers
;
NtCurrentTeb
()
->
ThreadLocalStoragePointer
=
pointers
;
#if defined(__APPLE__) && defined(__x86_64__)
#ifdef __x86_64__
/* macOS-specific hack */
__asm__
volatile
(
".byte 0x65
\n\t
movq %0,%c1"
if
(
NtCurrentTeb
()
->
Reserved5
[
0
])
:
((
TEB
*
)
NtCurrentTeb
()
->
Reserved5
[
0
])
->
ThreadLocalStoragePointer
=
pointers
;
:
"r"
(
pointers
),
"n"
(
FIELD_OFFSET
(
TEB
,
ThreadLocalStoragePointer
)));
#endif
#endif
return
STATUS_SUCCESS
;
return
STATUS_SUCCESS
;
}
}
...
...
dlls/ntdll/loadorder.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdlib.h>
#include <string.h>
#include <string.h>
...
@@ -64,7 +61,7 @@ static struct loadorder_list env_list;
...
@@ -64,7 +61,7 @@ static struct loadorder_list env_list;
* Sorting and comparing function used in sort and search of loadorder
* Sorting and comparing function used in sort and search of loadorder
* entries.
* entries.
*/
*/
static
int
cmp_sort_func
(
const
void
*
s1
,
const
void
*
s2
)
static
int
__cdecl
cmp_sort_func
(
const
void
*
s1
,
const
void
*
s2
)
{
{
return
wcsicmp
(((
const
module_loadorder_t
*
)
s1
)
->
modulename
,
((
const
module_loadorder_t
*
)
s2
)
->
modulename
);
return
wcsicmp
(((
const
module_loadorder_t
*
)
s1
)
->
modulename
,
((
const
module_loadorder_t
*
)
s2
)
->
modulename
);
}
}
...
...
dlls/ntdll/locale.c
View file @
8a169390
...
@@ -19,8 +19,6 @@
...
@@ -19,8 +19,6 @@
*/
*/
#define NONAMELESSUNION
#define NONAMELESSUNION
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include <string.h>
#include <string.h>
...
@@ -723,11 +721,6 @@ void init_locale( HMODULE module )
...
@@ -723,11 +721,6 @@ void init_locale( HMODULE module )
WCHAR
user_locale
[
LOCALE_NAME_MAX_LENGTH
];
WCHAR
user_locale
[
LOCALE_NAME_MAX_LENGTH
];
LCID
system_lcid
,
user_lcid
;
LCID
system_lcid
,
user_lcid
;
#ifdef __APPLE__
const
struct
norm_table
*
info
;
load_norm_table
(
NormalizationC
,
&
info
);
#endif
kernel32_handle
=
module
;
kernel32_handle
=
module
;
unix_funcs
->
get_locales
(
system_locale
,
user_locale
);
unix_funcs
->
get_locales
(
system_locale
,
user_locale
);
...
@@ -754,13 +747,7 @@ DWORD ntdll_umbstowcs( const char *src, DWORD srclen, WCHAR *dst, DWORD dstlen )
...
@@ -754,13 +747,7 @@ DWORD ntdll_umbstowcs( const char *src, DWORD srclen, WCHAR *dst, DWORD dstlen )
RtlCustomCPToUnicodeN
(
&
unix_table
,
dst
,
dstlen
*
sizeof
(
WCHAR
),
&
reslen
,
src
,
srclen
);
RtlCustomCPToUnicodeN
(
&
unix_table
,
dst
,
dstlen
*
sizeof
(
WCHAR
),
&
reslen
,
src
,
srclen
);
else
else
RtlUTF8ToUnicodeN
(
dst
,
dstlen
*
sizeof
(
WCHAR
),
&
reslen
,
src
,
srclen
);
RtlUTF8ToUnicodeN
(
dst
,
dstlen
*
sizeof
(
WCHAR
),
&
reslen
,
src
,
srclen
);
return
reslen
/
sizeof
(
WCHAR
);
reslen
/=
sizeof
(
WCHAR
);
#ifdef __APPLE__
/* work around broken Mac OS X filesystem that enforces decomposed Unicode */
if
(
reslen
&&
dst
&&
norm_tables
[
NormalizationC
])
reslen
=
compose_string
(
norm_tables
[
NormalizationC
],
dst
,
reslen
);
#endif
return
reslen
;
}
}
...
...
dlls/ntdll/misc.c
View file @
8a169390
...
@@ -19,8 +19,6 @@
...
@@ -19,8 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include <time.h>
#include <time.h>
#include <math.h>
#include <math.h>
...
@@ -257,8 +255,8 @@ NTDLL_mergesort( void *arr, void *barr, size_t elemsize, int(__cdecl *compar)(co
...
@@ -257,8 +255,8 @@ NTDLL_mergesort( void *arr, void *barr, size_t elemsize, int(__cdecl *compar)(co
/*********************************************************************
/*********************************************************************
* qsort (NTDLL.@)
* qsort (NTDLL.@)
*/
*/
void
__cdecl
NTDLL_
qsort
(
void
*
base
,
size_t
nmemb
,
size_t
size
,
void
__cdecl
qsort
(
void
*
base
,
size_t
nmemb
,
size_t
size
,
int
(
__cdecl
*
compar
)(
const
void
*
,
const
void
*
)
)
int
(
__cdecl
*
compar
)(
const
void
*
,
const
void
*
)
)
{
{
void
*
secondarr
;
void
*
secondarr
;
if
(
nmemb
<
2
||
size
==
0
)
return
;
if
(
nmemb
<
2
||
size
==
0
)
return
;
...
@@ -270,8 +268,7 @@ void __cdecl NTDLL_qsort( void *base, size_t nmemb, size_t size,
...
@@ -270,8 +268,7 @@ void __cdecl NTDLL_qsort( void *base, size_t nmemb, size_t size,
/*********************************************************************
/*********************************************************************
* bsearch (NTDLL.@)
* bsearch (NTDLL.@)
*/
*/
void
*
__cdecl
void
*
__cdecl
bsearch
(
const
void
*
key
,
const
void
*
base
,
size_t
nmemb
,
NTDLL_bsearch
(
const
void
*
key
,
const
void
*
base
,
size_t
nmemb
,
size_t
size
,
int
(
__cdecl
*
compar
)(
const
void
*
,
const
void
*
)
)
size_t
size
,
int
(
__cdecl
*
compar
)(
const
void
*
,
const
void
*
)
)
{
{
ssize_t
min
=
0
;
ssize_t
min
=
0
;
...
...
dlls/ntdll/nt.c
View file @
8a169390
...
@@ -21,9 +21,6 @@
...
@@ -21,9 +21,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <string.h>
#include <string.h>
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
...
...
dlls/ntdll/ntdll.spec
View file @
8a169390
...
@@ -1470,7 +1470,7 @@
...
@@ -1470,7 +1470,7 @@
@ cdecl _ui64tow(int64 ptr long)
@ cdecl _ui64tow(int64 ptr long)
@ cdecl _ultoa(long ptr long)
@ cdecl _ultoa(long ptr long)
@ cdecl _ultow(long ptr long)
@ cdecl _ultow(long ptr long)
@ cdecl -norelay _vsnprintf(ptr long str ptr)
NTDLL__vsnprintf
@ cdecl -norelay _vsnprintf(ptr long str ptr)
@ cdecl _vsnprintf_s(ptr long str ptr)
@ cdecl _vsnprintf_s(ptr long str ptr)
@ cdecl _vsnwprintf(ptr long wstr ptr) NTDLL__vsnwprintf
@ cdecl _vsnwprintf(ptr long wstr ptr) NTDLL__vsnwprintf
@ cdecl _vsnwprintf_s(ptr long long wstr ptr)
@ cdecl _vsnwprintf_s(ptr long long wstr ptr)
...
@@ -1486,7 +1486,7 @@
...
@@ -1486,7 +1486,7 @@
@ cdecl atan(double) NTDLL_atan
@ cdecl atan(double) NTDLL_atan
@ cdecl atoi(str) NTDLL_atoi
@ cdecl atoi(str) NTDLL_atoi
@ cdecl atol(str) NTDLL_atol
@ cdecl atol(str) NTDLL_atol
@ cdecl bsearch(ptr ptr long long ptr)
NTDLL_bsearch
@ cdecl bsearch(ptr ptr long long ptr)
@ cdecl ceil(double) NTDLL_ceil
@ cdecl ceil(double) NTDLL_ceil
@ cdecl cos(double) NTDLL_cos
@ cdecl cos(double) NTDLL_cos
@ cdecl fabs(double) NTDLL_fabs
@ cdecl fabs(double) NTDLL_fabs
...
@@ -1512,12 +1512,12 @@
...
@@ -1512,12 +1512,12 @@
@ cdecl log(double) NTDLL_log
@ cdecl log(double) NTDLL_log
@ cdecl mbstowcs(ptr str long) NTDLL_mbstowcs
@ cdecl mbstowcs(ptr str long) NTDLL_mbstowcs
@ cdecl memchr(ptr long long) NTDLL_memchr
@ cdecl memchr(ptr long long) NTDLL_memchr
@ cdecl memcmp(ptr ptr long)
NTDLL_memcmp
@ cdecl memcmp(ptr ptr long)
@ cdecl memcpy(ptr ptr long)
NTDLL_memcpy
@ cdecl memcpy(ptr ptr long)
@ cdecl memmove(ptr ptr long)
NTDLL_memmove
@ cdecl memmove(ptr ptr long)
@ cdecl memset(ptr long long)
NTDLL_memset
@ cdecl memset(ptr long long)
@ cdecl pow(double double) NTDLL_pow
@ cdecl pow(double double) NTDLL_pow
@ cdecl qsort(ptr long long ptr)
NTDLL_qsort
@ cdecl qsort(ptr long long ptr)
@ cdecl sin(double) NTDLL_sin
@ cdecl sin(double) NTDLL_sin
@ varargs sprintf(ptr str) NTDLL_sprintf
@ varargs sprintf(ptr str) NTDLL_sprintf
@ varargs sprintf_s(ptr long str)
@ varargs sprintf_s(ptr long str)
...
...
dlls/ntdll/ntdll_misc.h
View file @
8a169390
...
@@ -20,9 +20,7 @@
...
@@ -20,9 +20,7 @@
#define __WINE_NTDLL_MISC_H
#define __WINE_NTDLL_MISC_H
#include <stdarg.h>
#include <stdarg.h>
#include <signal.h>
#include <sys/types.h>
#include <sys/types.h>
#include <pthread.h>
#include "windef.h"
#include "windef.h"
#include "winnt.h"
#include "winnt.h"
...
@@ -129,7 +127,6 @@ struct ntdll_thread_data
...
@@ -129,7 +127,6 @@ struct ntdll_thread_data
int
reply_fd
;
/* fd for receiving server replies */
int
reply_fd
;
/* fd for receiving server replies */
int
wait_fd
[
2
];
/* fd for sleeping server requests */
int
wait_fd
[
2
];
/* fd for sleeping server requests */
BOOL
wow64_redir
;
/* Wow64 filesystem redirection flag */
BOOL
wow64_redir
;
/* Wow64 filesystem redirection flag */
pthread_t
pthread_id
;
/* pthread thread id */
};
};
C_ASSERT
(
sizeof
(
struct
ntdll_thread_data
)
<=
sizeof
(((
TEB
*
)
0
)
->
GdiTebBatch
)
);
C_ASSERT
(
sizeof
(
struct
ntdll_thread_data
)
<=
sizeof
(((
TEB
*
)
0
)
->
GdiTebBatch
)
);
...
@@ -162,7 +159,6 @@ LONG __cdecl NTDLL_strtol( const char *s, char **end, int base );
...
@@ -162,7 +159,6 @@ LONG __cdecl NTDLL_strtol( const char *s, char **end, int base );
ULONG
__cdecl
NTDLL_strtoul
(
const
char
*
s
,
char
**
end
,
int
base
);
ULONG
__cdecl
NTDLL_strtoul
(
const
char
*
s
,
char
**
end
,
int
base
);
int
__cdecl
NTDLL_atoi
(
const
char
*
nptr
);
int
__cdecl
NTDLL_atoi
(
const
char
*
nptr
);
int
__cdecl
NTDLL_tolower
(
int
c
);
int
__cdecl
NTDLL_tolower
(
int
c
);
int
__cdecl
_stricmp
(
LPCSTR
str1
,
LPCSTR
str2
);
int
__cdecl
NTDLL__wcsicmp
(
LPCWSTR
str1
,
LPCWSTR
str2
);
int
__cdecl
NTDLL__wcsicmp
(
LPCWSTR
str1
,
LPCWSTR
str2
);
int
__cdecl
NTDLL__wcsnicmp
(
LPCWSTR
str1
,
LPCWSTR
str2
,
size_t
n
);
int
__cdecl
NTDLL__wcsnicmp
(
LPCWSTR
str1
,
LPCWSTR
str2
,
size_t
n
);
int
__cdecl
NTDLL_wcscmp
(
LPCWSTR
str1
,
LPCWSTR
str2
);
int
__cdecl
NTDLL_wcscmp
(
LPCWSTR
str1
,
LPCWSTR
str2
);
...
@@ -186,7 +182,6 @@ LPWSTR __cdecl NTDLL_wcstok( LPWSTR str, LPCWSTR delim );
...
@@ -186,7 +182,6 @@ LPWSTR __cdecl NTDLL_wcstok( LPWSTR str, LPCWSTR delim );
LONG
__cdecl
NTDLL_wcstol
(
LPCWSTR
s
,
LPWSTR
*
end
,
INT
base
);
LONG
__cdecl
NTDLL_wcstol
(
LPCWSTR
s
,
LPWSTR
*
end
,
INT
base
);
ULONG
__cdecl
NTDLL_wcstoul
(
LPCWSTR
s
,
LPWSTR
*
end
,
INT
base
);
ULONG
__cdecl
NTDLL_wcstoul
(
LPCWSTR
s
,
LPWSTR
*
end
,
INT
base
);
int
WINAPIV
NTDLL_swprintf
(
WCHAR
*
str
,
const
WCHAR
*
format
,
...
);
int
WINAPIV
NTDLL_swprintf
(
WCHAR
*
str
,
const
WCHAR
*
format
,
...
);
int
WINAPIV
_snwprintf_s
(
WCHAR
*
str
,
SIZE_T
size
,
SIZE_T
len
,
const
WCHAR
*
format
,
...
);
#define memchr(p,c,n) NTDLL_memchr(p,c,n)
#define memchr(p,c,n) NTDLL_memchr(p,c,n)
#define strcat(d,s) NTDLL_strcat(d,s)
#define strcat(d,s) NTDLL_strcat(d,s)
...
...
dlls/ntdll/om.c
View file @
8a169390
...
@@ -19,14 +19,9 @@
...
@@ -19,14 +19,9 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include <stdarg.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdlib.h>
#include <string.h>
#include <string.h>
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#include "ntstatus.h"
#include "ntstatus.h"
#define WIN32_NO_STATUS
#define WIN32_NO_STATUS
...
...
dlls/ntdll/path.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include <sys/types.h>
#include <sys/types.h>
...
@@ -30,7 +27,6 @@
...
@@ -30,7 +27,6 @@
#include "windef.h"
#include "windef.h"
#include "winioctl.h"
#include "winioctl.h"
#include "wine/debug.h"
#include "wine/debug.h"
#include "wine/library.h"
#include "ntdll_misc.h"
#include "ntdll_misc.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
file
);
WINE_DEFAULT_DEBUG_CHANNEL
(
file
);
...
...
dlls/ntdll/printf.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <ctype.h>
#include <ctype.h>
#include <stdarg.h>
#include <stdarg.h>
...
@@ -593,7 +590,7 @@ static int pf_vsnprintf( pf_output *out, const WCHAR *format, __ms_va_list valis
...
@@ -593,7 +590,7 @@ static int pf_vsnprintf( pf_output *out, const WCHAR *format, __ms_va_list valis
/*********************************************************************
/*********************************************************************
* _vsnprintf (NTDLL.@)
* _vsnprintf (NTDLL.@)
*/
*/
int
CDECL
NTDLL__vsnprintf
(
char
*
str
,
SIZE_T
len
,
const
char
*
format
,
__ms_va_list
args
)
int
CDECL
_vsnprintf
(
char
*
str
,
size_t
len
,
const
char
*
format
,
__ms_va_list
args
)
{
{
DWORD
sz
;
DWORD
sz
;
LPWSTR
formatW
=
NULL
;
LPWSTR
formatW
=
NULL
;
...
@@ -646,7 +643,7 @@ int WINAPIV NTDLL__snprintf( char *str, SIZE_T len, const char *format, ... )
...
@@ -646,7 +643,7 @@ int WINAPIV NTDLL__snprintf( char *str, SIZE_T len, const char *format, ... )
__ms_va_list
valist
;
__ms_va_list
valist
;
__ms_va_start
(
valist
,
format
);
__ms_va_start
(
valist
,
format
);
ret
=
NTDLL_
_vsnprintf
(
str
,
len
,
format
,
valist
);
ret
=
_vsnprintf
(
str
,
len
,
format
,
valist
);
__ms_va_end
(
valist
);
__ms_va_end
(
valist
);
return
ret
;
return
ret
;
}
}
...
@@ -670,7 +667,7 @@ int WINAPIV NTDLL__snwprintf( WCHAR *str, SIZE_T len, const WCHAR *format, ... )
...
@@ -670,7 +667,7 @@ int WINAPIV NTDLL__snwprintf( WCHAR *str, SIZE_T len, const WCHAR *format, ... )
/*********************************************************************
/*********************************************************************
* _vsnprintf_s (NTDLL.@)
* _vsnprintf_s (NTDLL.@)
*/
*/
int
CDECL
_vsnprintf_s
(
char
*
str
,
SIZE_T
size
,
SIZE_T
len
,
const
char
*
format
,
__ms_va_list
args
)
int
CDECL
_vsnprintf_s
(
char
*
str
,
size_t
size
,
size_t
len
,
const
char
*
format
,
__ms_va_list
args
)
{
{
DWORD
sz
;
DWORD
sz
;
LPWSTR
formatW
=
NULL
;
LPWSTR
formatW
=
NULL
;
...
@@ -700,7 +697,7 @@ int CDECL _vsnprintf_s( char *str, SIZE_T size, SIZE_T len, const char *format,
...
@@ -700,7 +697,7 @@ int CDECL _vsnprintf_s( char *str, SIZE_T size, SIZE_T len, const char *format,
/***********************************************************************
/***********************************************************************
* _vsnwprintf_s (NTDLL.@)
* _vsnwprintf_s (NTDLL.@)
*/
*/
int
CDECL
_vsnwprintf_s
(
WCHAR
*
str
,
SIZE_T
size
,
SIZE_T
len
,
const
WCHAR
*
format
,
__ms_va_list
args
)
int
CDECL
_vsnwprintf_s
(
WCHAR
*
str
,
size_t
size
,
size_t
len
,
const
WCHAR
*
format
,
__ms_va_list
args
)
{
{
pf_output
out
;
pf_output
out
;
int
r
;
int
r
;
...
@@ -721,7 +718,7 @@ int CDECL _vsnwprintf_s( WCHAR *str, SIZE_T size, SIZE_T len, const WCHAR *forma
...
@@ -721,7 +718,7 @@ int CDECL _vsnwprintf_s( WCHAR *str, SIZE_T size, SIZE_T len, const WCHAR *forma
/*********************************************************************
/*********************************************************************
* _snprintf_s (NTDLL.@)
* _snprintf_s (NTDLL.@)
*/
*/
int
WINAPIV
_snprintf_s
(
char
*
str
,
SIZE_T
size
,
SIZE_T
len
,
const
char
*
format
,
...
)
int
WINAPIV
_snprintf_s
(
char
*
str
,
size_t
size
,
size_t
len
,
const
char
*
format
,
...
)
{
{
int
ret
;
int
ret
;
__ms_va_list
valist
;
__ms_va_list
valist
;
...
@@ -736,7 +733,7 @@ int WINAPIV _snprintf_s( char *str, SIZE_T size, SIZE_T len, const char *format,
...
@@ -736,7 +733,7 @@ int WINAPIV _snprintf_s( char *str, SIZE_T size, SIZE_T len, const char *format,
/*********************************************************************
/*********************************************************************
* _snwprintf_s (NTDLL.@)
* _snwprintf_s (NTDLL.@)
*/
*/
int
WINAPIV
_snwprintf_s
(
WCHAR
*
str
,
SIZE_T
size
,
SIZE_T
len
,
const
WCHAR
*
format
,
...
)
int
WINAPIV
_snwprintf_s
(
WCHAR
*
str
,
size_t
size
,
size_t
len
,
const
WCHAR
*
format
,
...
)
{
{
int
ret
;
int
ret
;
__ms_va_list
valist
;
__ms_va_list
valist
;
...
@@ -753,14 +750,14 @@ int WINAPIV _snwprintf_s( WCHAR *str, SIZE_T size, SIZE_T len, const WCHAR *form
...
@@ -753,14 +750,14 @@ int WINAPIV _snwprintf_s( WCHAR *str, SIZE_T size, SIZE_T len, const WCHAR *form
*/
*/
int
CDECL
NTDLL_vsprintf
(
char
*
str
,
const
char
*
format
,
__ms_va_list
args
)
int
CDECL
NTDLL_vsprintf
(
char
*
str
,
const
char
*
format
,
__ms_va_list
args
)
{
{
return
NTDLL_
_vsnprintf
(
str
,
size_max
,
format
,
args
);
return
_vsnprintf
(
str
,
size_max
,
format
,
args
);
}
}
/*********************************************************************
/*********************************************************************
* vsprintf_s (NTDLL.@)
* vsprintf_s (NTDLL.@)
*/
*/
int
CDECL
vsprintf_s
(
char
*
str
,
SIZE_T
size
,
const
char
*
format
,
__ms_va_list
args
)
int
CDECL
vsprintf_s
(
char
*
str
,
size_t
size
,
const
char
*
format
,
__ms_va_list
args
)
{
{
return
_vsnprintf_s
(
str
,
size
,
size
,
format
,
args
);
return
_vsnprintf_s
(
str
,
size
,
size
,
format
,
args
);
}
}
...
@@ -778,7 +775,7 @@ int CDECL NTDLL__vswprintf( WCHAR *str, const WCHAR *format, __ms_va_list args )
...
@@ -778,7 +775,7 @@ int CDECL NTDLL__vswprintf( WCHAR *str, const WCHAR *format, __ms_va_list args )
/*********************************************************************
/*********************************************************************
* vswprintf_s (NTDLL.@)
* vswprintf_s (NTDLL.@)
*/
*/
int
CDECL
vswprintf_s
(
WCHAR
*
str
,
SIZE_T
size
,
const
WCHAR
*
format
,
__ms_va_list
args
)
int
CDECL
vswprintf_s
(
WCHAR
*
str
,
size_t
size
,
const
WCHAR
*
format
,
__ms_va_list
args
)
{
{
return
_vsnwprintf_s
(
str
,
size
,
size
,
format
,
args
);
return
_vsnwprintf_s
(
str
,
size
,
size
,
format
,
args
);
}
}
...
@@ -793,7 +790,7 @@ int WINAPIV NTDLL_sprintf( char *str, const char *format, ... )
...
@@ -793,7 +790,7 @@ int WINAPIV NTDLL_sprintf( char *str, const char *format, ... )
__ms_va_list
valist
;
__ms_va_list
valist
;
__ms_va_start
(
valist
,
format
);
__ms_va_start
(
valist
,
format
);
ret
=
NTDLL_
_vsnprintf
(
str
,
size_max
,
format
,
valist
);
ret
=
_vsnprintf
(
str
,
size_max
,
format
,
valist
);
__ms_va_end
(
valist
);
__ms_va_end
(
valist
);
return
ret
;
return
ret
;
}
}
...
@@ -802,7 +799,7 @@ int WINAPIV NTDLL_sprintf( char *str, const char *format, ... )
...
@@ -802,7 +799,7 @@ int WINAPIV NTDLL_sprintf( char *str, const char *format, ... )
/*********************************************************************
/*********************************************************************
* sprintf_s (NTDLL.@)
* sprintf_s (NTDLL.@)
*/
*/
int
WINAPIV
sprintf_s
(
char
*
str
,
SIZE_T
size
,
const
char
*
format
,
...
)
int
WINAPIV
sprintf_s
(
char
*
str
,
size_t
size
,
const
char
*
format
,
...
)
{
{
int
ret
;
int
ret
;
__ms_va_list
valist
;
__ms_va_list
valist
;
...
@@ -832,7 +829,7 @@ int WINAPIV NTDLL_swprintf( WCHAR *str, const WCHAR *format, ... )
...
@@ -832,7 +829,7 @@ int WINAPIV NTDLL_swprintf( WCHAR *str, const WCHAR *format, ... )
/***********************************************************************
/***********************************************************************
* swprintf_s (NTDLL.@)
* swprintf_s (NTDLL.@)
*/
*/
int
WINAPIV
swprintf_s
(
WCHAR
*
str
,
SIZE_T
size
,
const
WCHAR
*
format
,
...
)
int
WINAPIV
swprintf_s
(
WCHAR
*
str
,
size_t
size
,
const
WCHAR
*
format
,
...
)
{
{
int
ret
;
int
ret
;
__ms_va_list
valist
;
__ms_va_list
valist
;
...
...
dlls/ntdll/process.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <errno.h>
#include <errno.h>
#include <fcntl.h>
#include <fcntl.h>
#include <stdarg.h>
#include <stdarg.h>
...
...
dlls/ntdll/reg.c
View file @
8a169390
...
@@ -26,16 +26,12 @@
...
@@ -26,16 +26,12 @@
* HKEY_CLASSES \\REGISTRY\\MACHINE\\SOFTWARE\\CLASSES
* HKEY_CLASSES \\REGISTRY\\MACHINE\\SOFTWARE\\CLASSES
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
#include <string.h>
#include <string.h>
#include "ntstatus.h"
#include "ntstatus.h"
#define WIN32_NO_STATUS
#define WIN32_NO_STATUS
#include "wine/library.h"
#include "ntdll_misc.h"
#include "ntdll_misc.h"
#include "wine/debug.h"
#include "wine/debug.h"
...
...
dlls/ntdll/relay.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <string.h>
#include <string.h>
#include <stdarg.h>
#include <stdarg.h>
...
...
dlls/ntdll/resource.c
View file @
8a169390
...
@@ -25,9 +25,6 @@
...
@@ -25,9 +25,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdlib.h>
#include <sys/types.h>
#include <sys/types.h>
...
...
dlls/ntdll/rtl.c
View file @
8a169390
...
@@ -23,27 +23,18 @@
...
@@ -23,27 +23,18 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdlib.h>
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <string.h>
#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
#include "ntstatus.h"
#include "ntstatus.h"
#define NONAMELESSUNION
#define NONAMELESSUNION
#define NONAMELESSSTRUCT
#define NONAMELESSSTRUCT
#define WIN32_NO_STATUS
#define WIN32_NO_STATUS
#
define USE_WS_PREFIX
#
include "winsock2.h"
#include "windef.h"
#include "windef.h"
#include "winternl.h"
#include "winternl.h"
#include "wine/debug.h"
#include "wine/debug.h"
#include "wine/exception.h"
#include "wine/exception.h"
#include "ntdll_misc.h"
#include "ntdll_misc.h"
#include "inaddr.h"
#include "in6addr.h"
#include "in6addr.h"
#include "ddk/ntddk.h"
#include "ddk/ntddk.h"
...
@@ -333,7 +324,7 @@ NTSTATUS WINAPIV DbgPrint(LPCSTR fmt, ...)
...
@@ -333,7 +324,7 @@ NTSTATUS WINAPIV DbgPrint(LPCSTR fmt, ...)
__ms_va_list
args
;
__ms_va_list
args
;
__ms_va_start
(
args
,
fmt
);
__ms_va_start
(
args
,
fmt
);
NTDLL_
_vsnprintf
(
buf
,
sizeof
(
buf
),
fmt
,
args
);
_vsnprintf
(
buf
,
sizeof
(
buf
),
fmt
,
args
);
__ms_va_end
(
args
);
__ms_va_end
(
args
);
MESSAGE
(
"DbgPrint says: %s"
,
buf
);
MESSAGE
(
"DbgPrint says: %s"
,
buf
);
...
@@ -371,7 +362,7 @@ NTSTATUS WINAPI vDbgPrintExWithPrefix( LPCSTR prefix, ULONG id, ULONG level, LPC
...
@@ -371,7 +362,7 @@ NTSTATUS WINAPI vDbgPrintExWithPrefix( LPCSTR prefix, ULONG id, ULONG level, LPC
{
{
char
buf
[
1024
];
char
buf
[
1024
];
NTDLL_
_vsnprintf
(
buf
,
sizeof
(
buf
),
fmt
,
args
);
_vsnprintf
(
buf
,
sizeof
(
buf
),
fmt
,
args
);
switch
(
level
&
DPFLTR_MASK
)
switch
(
level
&
DPFLTR_MASK
)
{
{
...
...
dlls/ntdll/rtlbitmap.c
View file @
8a169390
...
@@ -662,7 +662,7 @@ CCHAR WINAPI RtlFindLeastSignificantBit(ULONGLONG ulLong)
...
@@ -662,7 +662,7 @@ CCHAR WINAPI RtlFindLeastSignificantBit(ULONGLONG ulLong)
*
*
* Internal helper: qsort comparison function for RTL_BITMAP_RUN arrays
* Internal helper: qsort comparison function for RTL_BITMAP_RUN arrays
*/
*/
static
int
NTDLL_RunSortFn
(
const
void
*
lhs
,
const
void
*
rhs
)
static
int
__cdecl
NTDLL_RunSortFn
(
const
void
*
lhs
,
const
void
*
rhs
)
{
{
if
(((
const
RTL_BITMAP_RUN
*
)
lhs
)
->
NumberOfBits
>
((
const
RTL_BITMAP_RUN
*
)
rhs
)
->
NumberOfBits
)
if
(((
const
RTL_BITMAP_RUN
*
)
lhs
)
->
NumberOfBits
>
((
const
RTL_BITMAP_RUN
*
)
rhs
)
->
NumberOfBits
)
return
-
1
;
return
-
1
;
...
...
dlls/ntdll/rtlstr.c
View file @
8a169390
...
@@ -20,8 +20,6 @@
...
@@ -20,8 +20,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include <assert.h>
#include <assert.h>
#include <stdarg.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdlib.h>
...
...
dlls/ntdll/sec.c
View file @
8a169390
...
@@ -19,25 +19,18 @@
...
@@ -19,25 +19,18 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdlib.h>
#include <string.h>
#include <string.h>
#include <time.h>
#include <time.h>
#include <ctype.h>
#include <ctype.h>
#include <math.h>
#include <math.h>
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#include "ntstatus.h"
#include "ntstatus.h"
#define WIN32_NO_STATUS
#define WIN32_NO_STATUS
#include "windef.h"
#include "windef.h"
#include "ntdll_misc.h"
#include "ntdll_misc.h"
#include "wine/exception.h"
#include "wine/exception.h"
#include "wine/library.h"
#include "wine/debug.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
ntdll
);
WINE_DEFAULT_DEBUG_CHANNEL
(
ntdll
);
...
...
dlls/ntdll/server.c
View file @
8a169390
...
@@ -18,9 +18,6 @@
...
@@ -18,9 +18,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <ctype.h>
#include <ctype.h>
#include <stdarg.h>
#include <stdarg.h>
...
...
dlls/ntdll/signal_arm.c
View file @
8a169390
...
@@ -21,9 +21,6 @@
...
@@ -21,9 +21,6 @@
#ifdef __arm__
#ifdef __arm__
#include "config.h"
#include "wine/port.h"
#include <stdlib.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdarg.h>
...
...
dlls/ntdll/signal_arm64.c
View file @
8a169390
...
@@ -20,17 +20,11 @@
...
@@ -20,17 +20,11 @@
#ifdef __aarch64__
#ifdef __aarch64__
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <signal.h>
#include <signal.h>
#include <stdlib.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#define NONAMELESSUNION
#define NONAMELESSUNION
#define NONAMELESSSTRUCT
#define NONAMELESSSTRUCT
...
...
dlls/ntdll/signal_i386.c
View file @
8a169390
...
@@ -20,21 +20,12 @@
...
@@ -20,21 +20,12 @@
#ifdef __i386__
#ifdef __i386__
#include "config.h"
#include "wine/port.h"
#include <errno.h>
#include <errno.h>
#include <signal.h>
#include <signal.h>
#include <stdlib.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
#include <sys/types.h>
#include <sys/types.h>
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#ifdef HAVE_SYS_PARAM_H
# include <sys/param.h>
#endif
#include "ntstatus.h"
#include "ntstatus.h"
#define WIN32_NO_STATUS
#define WIN32_NO_STATUS
...
...
dlls/ntdll/signal_x86_64.c
View file @
8a169390
...
@@ -20,9 +20,6 @@
...
@@ -20,9 +20,6 @@
#ifdef __x86_64__
#ifdef __x86_64__
#include "config.h"
#include "wine/port.h"
#include <stdlib.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdarg.h>
...
...
dlls/ntdll/string.c
View file @
8a169390
...
@@ -20,9 +20,6 @@
...
@@ -20,9 +20,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <limits.h>
#include <limits.h>
#include <stdarg.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdlib.h>
...
@@ -83,7 +80,7 @@ void * __cdecl NTDLL_memchr( const void *ptr, int c, size_t n )
...
@@ -83,7 +80,7 @@ void * __cdecl NTDLL_memchr( const void *ptr, int c, size_t n )
/*********************************************************************
/*********************************************************************
* memcmp (NTDLL.@)
* memcmp (NTDLL.@)
*/
*/
int
__cdecl
NTDLL_
memcmp
(
const
void
*
ptr1
,
const
void
*
ptr2
,
size_t
n
)
int
__cdecl
memcmp
(
const
void
*
ptr1
,
const
void
*
ptr2
,
size_t
n
)
{
{
const
unsigned
char
*
p1
,
*
p2
;
const
unsigned
char
*
p1
,
*
p2
;
...
@@ -102,7 +99,7 @@ int __cdecl NTDLL_memcmp( const void *ptr1, const void *ptr2, size_t n )
...
@@ -102,7 +99,7 @@ int __cdecl NTDLL_memcmp( const void *ptr1, const void *ptr2, size_t n )
* NOTES
* NOTES
* Behaves like memmove.
* Behaves like memmove.
*/
*/
void
*
__cdecl
NTDLL_
memcpy
(
void
*
dst
,
const
void
*
src
,
size_t
n
)
void
*
__cdecl
memcpy
(
void
*
dst
,
const
void
*
src
,
size_t
n
)
{
{
volatile
unsigned
char
*
d
=
dst
;
/* avoid gcc optimizations */
volatile
unsigned
char
*
d
=
dst
;
/* avoid gcc optimizations */
const
unsigned
char
*
s
=
src
;
const
unsigned
char
*
s
=
src
;
...
@@ -124,7 +121,7 @@ void * __cdecl NTDLL_memcpy( void *dst, const void *src, size_t n )
...
@@ -124,7 +121,7 @@ void * __cdecl NTDLL_memcpy( void *dst, const void *src, size_t n )
/*********************************************************************
/*********************************************************************
* memmove (NTDLL.@)
* memmove (NTDLL.@)
*/
*/
void
*
__cdecl
NTDLL_
memmove
(
void
*
dst
,
const
void
*
src
,
size_t
n
)
void
*
__cdecl
memmove
(
void
*
dst
,
const
void
*
src
,
size_t
n
)
{
{
volatile
unsigned
char
*
d
=
dst
;
/* avoid gcc optimizations */
volatile
unsigned
char
*
d
=
dst
;
/* avoid gcc optimizations */
const
unsigned
char
*
s
=
src
;
const
unsigned
char
*
s
=
src
;
...
@@ -146,7 +143,7 @@ void * __cdecl NTDLL_memmove( void *dst, const void *src, size_t n )
...
@@ -146,7 +143,7 @@ void * __cdecl NTDLL_memmove( void *dst, const void *src, size_t n )
/*********************************************************************
/*********************************************************************
* memset (NTDLL.@)
* memset (NTDLL.@)
*/
*/
void
*
__cdecl
NTDLL_
memset
(
void
*
dst
,
int
c
,
size_t
n
)
void
*
__cdecl
memset
(
void
*
dst
,
int
c
,
size_t
n
)
{
{
volatile
unsigned
char
*
d
=
dst
;
/* avoid gcc optimizations */
volatile
unsigned
char
*
d
=
dst
;
/* avoid gcc optimizations */
while
(
n
--
)
*
d
++
=
c
;
while
(
n
--
)
*
d
++
=
c
;
...
@@ -729,10 +726,7 @@ ULONG __cdecl NTDLL_strtoul( const char *s, char **end, int base )
...
@@ -729,10 +726,7 @@ ULONG __cdecl NTDLL_strtoul( const char *s, char **end, int base )
* - Does not check if radix is in the range of 2 to 36.
* - Does not check if radix is in the range of 2 to 36.
* - If str is NULL it crashes, as the native function does.
* - If str is NULL it crashes, as the native function does.
*/
*/
char
*
__cdecl
_ultoa
(
char
*
__cdecl
_ultoa
(
__msvcrt_ulong
value
,
char
*
str
,
int
radix
)
ULONG
value
,
/* [I] Value to be converted */
char
*
str
,
/* [O] Destination for the converted value */
int
radix
)
/* [I] Number base for conversion */
{
{
char
buffer
[
33
];
char
buffer
[
33
];
char
*
pos
;
char
*
pos
;
...
@@ -771,10 +765,7 @@ char * __cdecl _ultoa(
...
@@ -771,10 +765,7 @@ char * __cdecl _ultoa(
* - Does not check if radix is in the range of 2 to 36.
* - Does not check if radix is in the range of 2 to 36.
* - If str is NULL it crashes, as the native function does.
* - If str is NULL it crashes, as the native function does.
*/
*/
char
*
__cdecl
_ltoa
(
char
*
__cdecl
_ltoa
(
__msvcrt_long
value
,
char
*
str
,
int
radix
)
LONG
value
,
/* [I] Value to be converted */
char
*
str
,
/* [O] Destination for the converted value */
int
radix
)
/* [I] Number base for conversion */
{
{
ULONG
val
;
ULONG
val
;
int
negative
;
int
negative
;
...
...
dlls/ntdll/sync.c
View file @
8a169390
...
@@ -21,9 +21,6 @@
...
@@ -21,9 +21,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <limits.h>
#include <limits.h>
#include <string.h>
#include <string.h>
#include <stdarg.h>
#include <stdarg.h>
...
...
dlls/ntdll/thread.c
View file @
8a169390
...
@@ -18,9 +18,6 @@
...
@@ -18,9 +18,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <stdarg.h>
#include <stdarg.h>
#include <limits.h>
#include <limits.h>
...
...
dlls/ntdll/threadpool.c
View file @
8a169390
...
@@ -19,9 +19,6 @@
...
@@ -19,9 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <stdarg.h>
#include <stdarg.h>
#include <limits.h>
#include <limits.h>
...
...
dlls/ntdll/time.c
View file @
8a169390
...
@@ -23,18 +23,12 @@
...
@@ -23,18 +23,12 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdarg.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdlib.h>
#include <errno.h>
#include <errno.h>
#include <string.h>
#include <string.h>
#include <limits.h>
#include <limits.h>
#include <time.h>
#include <time.h>
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#include "ntstatus.h"
#include "ntstatus.h"
#define WIN32_NO_STATUS
#define WIN32_NO_STATUS
...
...
dlls/ntdll/unix/loader.c
View file @
8a169390
...
@@ -1558,7 +1558,6 @@ static void start_main_thread(void)
...
@@ -1558,7 +1558,6 @@ static void start_main_thread(void)
server_init_process
();
server_init_process
();
startup_info_size
=
server_init_thread
(
teb
->
Peb
,
&
suspend
);
startup_info_size
=
server_init_thread
(
teb
->
Peb
,
&
suspend
);
virtual_map_user_shared_data
();
virtual_map_user_shared_data
();
virtual_create_builtin_view
(
ntdll_module
);
init_cpu_info
();
init_cpu_info
();
init_files
();
init_files
();
NtCreateKeyedEvent
(
&
keyed_event
,
GENERIC_READ
|
GENERIC_WRITE
,
NULL
,
0
);
NtCreateKeyedEvent
(
&
keyed_event
,
GENERIC_READ
|
GENERIC_WRITE
,
NULL
,
0
);
...
...
dlls/ntdll/version.c
View file @
8a169390
...
@@ -21,9 +21,6 @@
...
@@ -21,9 +21,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <string.h>
#include <string.h>
#include <stdlib.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdarg.h>
...
...
dlls/ntdll/virtual.c
View file @
8a169390
...
@@ -18,15 +18,8 @@
...
@@ -18,15 +18,8 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include <assert.h>
#include <errno.h>
#include <errno.h>
#include <fcntl.h>
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#include <stdarg.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdlib.h>
#include <stdio.h>
#include <stdio.h>
...
...
dlls/ntdll/wcstring.c
View file @
8a169390
...
@@ -20,8 +20,6 @@
...
@@ -20,8 +20,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "config.h"
#include <ctype.h>
#include <ctype.h>
#include <stdlib.h>
#include <stdlib.h>
#include <string.h>
#include <string.h>
...
@@ -573,10 +571,7 @@ ULONG __cdecl NTDLL_wcstoul(LPCWSTR s, LPWSTR *end, INT base)
...
@@ -573,10 +571,7 @@ ULONG __cdecl NTDLL_wcstoul(LPCWSTR s, LPWSTR *end, INT base)
* Does not check if radix is in the range of 2 to 36.
* Does not check if radix is in the range of 2 to 36.
* If str is NULL it just returns NULL.
* If str is NULL it just returns NULL.
*/
*/
LPWSTR
__cdecl
_ultow
(
LPWSTR
__cdecl
_ultow
(
__msvcrt_ulong
value
,
LPWSTR
str
,
INT
radix
)
ULONG
value
,
/* [I] Value to be converted */
LPWSTR
str
,
/* [O] Destination for the converted value */
INT
radix
)
/* [I] Number base for conversion */
{
{
WCHAR
buffer
[
33
];
WCHAR
buffer
[
33
];
PWCHAR
pos
;
PWCHAR
pos
;
...
@@ -617,10 +612,7 @@ LPWSTR __cdecl _ultow(
...
@@ -617,10 +612,7 @@ LPWSTR __cdecl _ultow(
* Does not check if radix is in the range of 2 to 36.
* Does not check if radix is in the range of 2 to 36.
* If str is NULL it just returns NULL.
* If str is NULL it just returns NULL.
*/
*/
LPWSTR
__cdecl
_ltow
(
LPWSTR
__cdecl
_ltow
(
__msvcrt_long
value
,
LPWSTR
str
,
INT
radix
)
LONG
value
,
/* [I] Value to be converted */
LPWSTR
str
,
/* [O] Destination for the converted value */
INT
radix
)
/* [I] Number base for conversion */
{
{
ULONG
val
;
ULONG
val
;
int
negative
;
int
negative
;
...
@@ -819,7 +811,7 @@ LPWSTR __cdecl _i64tow(
...
@@ -819,7 +811,7 @@ LPWSTR __cdecl _i64tow(
* No check is made for value overflow, only the lower 32 bits are assigned.
* No check is made for value overflow, only the lower 32 bits are assigned.
* If str is NULL it crashes, as the native function does.
* If str is NULL it crashes, as the native function does.
*/
*/
LONG
__cdecl
_wtol
(
LPCWSTR
str
)
__msvcrt_long
__cdecl
_wtol
(
LPCWSTR
str
)
{
{
ULONG
RunningTotal
=
0
;
ULONG
RunningTotal
=
0
;
BOOL
bMinus
=
FALSE
;
BOOL
bMinus
=
FALSE
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment