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
747b9753
Commit
747b9753
authored
Oct 22, 2021
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Use the standard va_list instead of __ms_va_list.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
d8ed47ec
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
73 additions
and
73 deletions
+73
-73
misc.c
dlls/ntdll/misc.c
+4
-4
ntdll_misc.h
dlls/ntdll/ntdll_misc.h
+2
-2
printf.c
dlls/ntdll/printf.c
+32
-32
printf.h
dlls/ntdll/printf.h
+1
-1
rtl.c
dlls/ntdll/rtl.c
+8
-8
rtlstr.c
dlls/ntdll/rtlstr.c
+3
-3
string.c
dlls/ntdll/string.c
+4
-4
rtl.c
dlls/ntdll/tests/rtl.c
+6
-6
rtlstr.c
dlls/ntdll/tests/rtlstr.c
+13
-13
No files found.
dlls/ntdll/misc.c
View file @
747b9753
...
...
@@ -515,7 +515,7 @@ ULONG WINAPI EtwLogTraceEvent( TRACEHANDLE SessionHandle, PEVENT_TRACE_HEADER Ev
* EtwTraceMessageVa (NTDLL.@)
*/
ULONG
WINAPI
EtwTraceMessageVa
(
TRACEHANDLE
handle
,
ULONG
flags
,
LPGUID
guid
,
USHORT
number
,
__ms_
va_list
args
)
va_list
args
)
{
FIXME
(
"(%s %x %s %d) : stub
\n
"
,
wine_dbgstr_longlong
(
handle
),
flags
,
debugstr_guid
(
guid
),
number
);
return
ERROR_SUCCESS
;
...
...
@@ -526,12 +526,12 @@ ULONG WINAPI EtwTraceMessageVa( TRACEHANDLE handle, ULONG flags, LPGUID guid, US
*/
ULONG
WINAPIV
EtwTraceMessage
(
TRACEHANDLE
handle
,
ULONG
flags
,
LPGUID
guid
,
/*USHORT*/
ULONG
number
,
...
)
{
__ms_
va_list
valist
;
va_list
valist
;
ULONG
ret
;
__ms_
va_start
(
valist
,
number
);
va_start
(
valist
,
number
);
ret
=
EtwTraceMessageVa
(
handle
,
flags
,
guid
,
number
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
...
...
dlls/ntdll/ntdll_misc.h
View file @
747b9753
...
...
@@ -85,8 +85,8 @@ extern const struct unix_funcs *unix_funcs DECLSPEC_HIDDEN;
extern
struct
_KUSER_SHARED_DATA
*
user_shared_data
DECLSPEC_HIDDEN
;
extern
int
CDECL
NTDLL__vsnprintf
(
char
*
str
,
SIZE_T
len
,
const
char
*
format
,
__ms_
va_list
args
)
DECLSPEC_HIDDEN
;
extern
int
CDECL
NTDLL__vsnwprintf
(
WCHAR
*
str
,
SIZE_T
len
,
const
WCHAR
*
format
,
__ms_
va_list
args
)
DECLSPEC_HIDDEN
;
extern
int
CDECL
NTDLL__vsnprintf
(
char
*
str
,
SIZE_T
len
,
const
char
*
format
,
va_list
args
)
DECLSPEC_HIDDEN
;
extern
int
CDECL
NTDLL__vsnwprintf
(
WCHAR
*
str
,
SIZE_T
len
,
const
WCHAR
*
format
,
va_list
args
)
DECLSPEC_HIDDEN
;
struct
dllredirect_data
{
...
...
dlls/ntdll/printf.c
View file @
747b9753
...
...
@@ -52,7 +52,7 @@ typedef struct pf_flags_t
/*********************************************************************
* _vsnprintf (NTDLL.@)
*/
int
CDECL
_vsnprintf
(
char
*
str
,
size_t
len
,
const
char
*
format
,
__ms_
va_list
args
)
int
CDECL
_vsnprintf
(
char
*
str
,
size_t
len
,
const
char
*
format
,
va_list
args
)
{
pf_output_a
out
=
{
str
,
len
};
int
r
=
pf_vsnprintf_a
(
&
out
,
format
,
args
);
...
...
@@ -65,7 +65,7 @@ int CDECL _vsnprintf( char *str, size_t len, const char *format, __ms_va_list ar
/***********************************************************************
* _vsnwprintf (NTDLL.@)
*/
int
CDECL
_vsnwprintf
(
WCHAR
*
str
,
size_t
len
,
const
WCHAR
*
format
,
__ms_
va_list
args
)
int
CDECL
_vsnwprintf
(
WCHAR
*
str
,
size_t
len
,
const
WCHAR
*
format
,
va_list
args
)
{
pf_output_w
out
=
{
str
,
len
};
int
r
=
pf_vsnprintf_w
(
&
out
,
format
,
args
);
...
...
@@ -81,11 +81,11 @@ int CDECL _vsnwprintf( WCHAR *str, size_t len, const WCHAR *format, __ms_va_list
int
WINAPIV
NTDLL__snprintf
(
char
*
str
,
size_t
len
,
const
char
*
format
,
...
)
{
int
ret
;
__ms_
va_list
valist
;
va_list
valist
;
__ms_
va_start
(
valist
,
format
);
va_start
(
valist
,
format
);
ret
=
_vsnprintf
(
str
,
len
,
format
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
...
...
@@ -96,11 +96,11 @@ int WINAPIV NTDLL__snprintf( char *str, size_t len, const char *format, ... )
int
WINAPIV
_snwprintf
(
WCHAR
*
str
,
size_t
len
,
const
WCHAR
*
format
,
...
)
{
int
ret
;
__ms_
va_list
valist
;
va_list
valist
;
__ms_
va_start
(
valist
,
format
);
va_start
(
valist
,
format
);
ret
=
_vsnwprintf
(
str
,
len
,
format
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
...
...
@@ -108,7 +108,7 @@ int WINAPIV _snwprintf( WCHAR *str, size_t len, const WCHAR *format, ... )
/*********************************************************************
* _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
,
va_list
args
)
{
pf_output_a
out
=
{
str
,
min
(
size
,
len
)
};
int
r
=
pf_vsnprintf_a
(
&
out
,
format
,
args
);
...
...
@@ -123,7 +123,7 @@ int CDECL _vsnprintf_s( char *str, size_t size, size_t len, const char *format,
/***********************************************************************
* _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
,
va_list
args
)
{
pf_output_w
out
=
{
str
,
min
(
size
,
len
)
};
int
r
=
pf_vsnprintf_w
(
&
out
,
format
,
args
);
...
...
@@ -141,11 +141,11 @@ int CDECL _vsnwprintf_s( WCHAR *str, size_t size, size_t len, const WCHAR *forma
int
WINAPIV
_snprintf_s
(
char
*
str
,
size_t
size
,
size_t
len
,
const
char
*
format
,
...
)
{
int
ret
;
__ms_
va_list
valist
;
va_list
valist
;
__ms_
va_start
(
valist
,
format
);
va_start
(
valist
,
format
);
ret
=
_vsnprintf_s
(
str
,
size
,
len
,
format
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
...
...
@@ -156,11 +156,11 @@ int WINAPIV _snprintf_s( char *str, size_t size, size_t len, const char *format,
int
WINAPIV
_snwprintf_s
(
WCHAR
*
str
,
size_t
size
,
size_t
len
,
const
WCHAR
*
format
,
...
)
{
int
ret
;
__ms_
va_list
valist
;
va_list
valist
;
__ms_
va_start
(
valist
,
format
);
va_start
(
valist
,
format
);
ret
=
_vsnwprintf_s
(
str
,
size
,
len
,
format
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
...
...
@@ -168,7 +168,7 @@ int WINAPIV _snwprintf_s( WCHAR *str, size_t size, size_t len, const WCHAR *form
/*********************************************************************
* vsprintf (NTDLL.@)
*/
int
CDECL
vsprintf
(
char
*
str
,
const
char
*
format
,
__ms_
va_list
args
)
int
CDECL
vsprintf
(
char
*
str
,
const
char
*
format
,
va_list
args
)
{
return
_vsnprintf
(
str
,
size_max
,
format
,
args
);
}
...
...
@@ -177,7 +177,7 @@ int CDECL vsprintf( char *str, const char *format, __ms_va_list args )
/*********************************************************************
* 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
,
va_list
args
)
{
return
_vsnprintf_s
(
str
,
size
,
size
,
format
,
args
);
}
...
...
@@ -186,7 +186,7 @@ int CDECL vsprintf_s( char *str, size_t size, const char *format, __ms_va_list a
/*********************************************************************
* _vswprintf (NTDLL.@)
*/
int
CDECL
_vswprintf
(
WCHAR
*
str
,
const
WCHAR
*
format
,
__ms_
va_list
args
)
int
CDECL
_vswprintf
(
WCHAR
*
str
,
const
WCHAR
*
format
,
va_list
args
)
{
return
_vsnwprintf
(
str
,
size_max
,
format
,
args
);
}
...
...
@@ -195,7 +195,7 @@ int CDECL _vswprintf( WCHAR *str, const WCHAR *format, __ms_va_list args )
/*********************************************************************
* 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
,
va_list
args
)
{
return
_vsnwprintf_s
(
str
,
size
,
size
,
format
,
args
);
}
...
...
@@ -207,11 +207,11 @@ int CDECL vswprintf_s( WCHAR *str, size_t size, const WCHAR *format, __ms_va_lis
int
WINAPIV
NTDLL_sprintf
(
char
*
str
,
const
char
*
format
,
...
)
{
int
ret
;
__ms_
va_list
valist
;
va_list
valist
;
__ms_
va_start
(
valist
,
format
);
va_start
(
valist
,
format
);
ret
=
_vsnprintf
(
str
,
size_max
,
format
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
...
...
@@ -222,11 +222,11 @@ int WINAPIV NTDLL_sprintf( char *str, const char *format, ... )
int
WINAPIV
sprintf_s
(
char
*
str
,
size_t
size
,
const
char
*
format
,
...
)
{
int
ret
;
__ms_
va_list
valist
;
va_list
valist
;
__ms_
va_start
(
valist
,
format
);
va_start
(
valist
,
format
);
ret
=
vsprintf_s
(
str
,
size
,
format
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
...
...
@@ -237,11 +237,11 @@ int WINAPIV sprintf_s( char *str, size_t size, const char *format, ... )
int
WINAPIV
NTDLL_swprintf
(
WCHAR
*
str
,
const
WCHAR
*
format
,
...
)
{
int
ret
;
__ms_
va_list
valist
;
va_list
valist
;
__ms_
va_start
(
valist
,
format
);
va_start
(
valist
,
format
);
ret
=
_vsnwprintf
(
str
,
size_max
,
format
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
...
...
@@ -252,10 +252,10 @@ int WINAPIV NTDLL_swprintf( WCHAR *str, const WCHAR *format, ... )
int
WINAPIV
swprintf_s
(
WCHAR
*
str
,
size_t
size
,
const
WCHAR
*
format
,
...
)
{
int
ret
;
__ms_
va_list
valist
;
va_list
valist
;
__ms_
va_start
(
valist
,
format
);
va_start
(
valist
,
format
);
ret
=
vswprintf_s
(
str
,
size
,
format
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
dlls/ntdll/printf.h
View file @
747b9753
...
...
@@ -283,7 +283,7 @@ static void FUNC_NAME(pf_integer_conv)( APICHAR *buf, pf_flags *flags, LONGLONG
}
}
static
int
FUNC_NAME
(
pf_vsnprintf
)(
FUNC_NAME
(
pf_output
)
*
out
,
const
APICHAR
*
format
,
__ms_
va_list
valist
)
static
int
FUNC_NAME
(
pf_vsnprintf
)(
FUNC_NAME
(
pf_output
)
*
out
,
const
APICHAR
*
format
,
va_list
valist
)
{
int
r
;
const
APICHAR
*
q
,
*
p
=
format
;
...
...
dlls/ntdll/rtl.c
View file @
747b9753
...
...
@@ -311,11 +311,11 @@ static LONG WINAPI debug_exception_handler( EXCEPTION_POINTERS *eptr )
NTSTATUS
WINAPIV
DbgPrint
(
LPCSTR
fmt
,
...)
{
NTSTATUS
ret
;
__ms_
va_list
args
;
va_list
args
;
__ms_
va_start
(
args
,
fmt
);
va_start
(
args
,
fmt
);
ret
=
vDbgPrintEx
(
0
,
DPFLTR_ERROR_LEVEL
,
fmt
,
args
);
__ms_
va_end
(
args
);
va_end
(
args
);
return
ret
;
}
...
...
@@ -326,18 +326,18 @@ NTSTATUS WINAPIV DbgPrint(LPCSTR fmt, ...)
NTSTATUS
WINAPIV
DbgPrintEx
(
ULONG
iComponentId
,
ULONG
Level
,
LPCSTR
fmt
,
...)
{
NTSTATUS
ret
;
__ms_
va_list
args
;
va_list
args
;
__ms_
va_start
(
args
,
fmt
);
va_start
(
args
,
fmt
);
ret
=
vDbgPrintEx
(
iComponentId
,
Level
,
fmt
,
args
);
__ms_
va_end
(
args
);
va_end
(
args
);
return
ret
;
}
/******************************************************************************
* vDbgPrintEx [NTDLL.@]
*/
NTSTATUS
WINAPI
vDbgPrintEx
(
ULONG
id
,
ULONG
level
,
LPCSTR
fmt
,
__ms_
va_list
args
)
NTSTATUS
WINAPI
vDbgPrintEx
(
ULONG
id
,
ULONG
level
,
LPCSTR
fmt
,
va_list
args
)
{
return
vDbgPrintExWithPrefix
(
""
,
id
,
level
,
fmt
,
args
);
}
...
...
@@ -345,7 +345,7 @@ NTSTATUS WINAPI vDbgPrintEx( ULONG id, ULONG level, LPCSTR fmt, __ms_va_list arg
/******************************************************************************
* vDbgPrintExWithPrefix [NTDLL.@]
*/
NTSTATUS
WINAPI
vDbgPrintExWithPrefix
(
LPCSTR
prefix
,
ULONG
id
,
ULONG
level
,
LPCSTR
fmt
,
__ms_
va_list
args
)
NTSTATUS
WINAPI
vDbgPrintExWithPrefix
(
LPCSTR
prefix
,
ULONG
id
,
ULONG
level
,
LPCSTR
fmt
,
va_list
args
)
{
ULONG
level_mask
=
level
<=
31
?
(
1
<<
level
)
:
level
;
SIZE_T
len
=
strlen
(
prefix
);
...
...
dlls/ntdll/rtlstr.c
View file @
747b9753
...
...
@@ -1709,7 +1709,7 @@ struct format_message_args
{
int
last
;
/* last used arg */
ULONG_PTR
*
array
;
/* args array */
__ms_va_list
*
list
;
/* args va_list */
va_list
*
list
;
/* args va_list */
UINT64
arglist
[
102
];
/* arguments fetched from va_list */
};
...
...
@@ -1808,7 +1808,7 @@ static NTSTATUS add_format( WCHAR **buffer, WCHAR *end, const WCHAR **src, int i
* RtlFormatMessage (NTDLL.@)
*/
NTSTATUS
WINAPI
RtlFormatMessage
(
const
WCHAR
*
src
,
ULONG
width
,
BOOLEAN
ignore_inserts
,
BOOLEAN
ansi
,
BOOLEAN
is_array
,
__ms_
va_list
*
args
,
BOOLEAN
ansi
,
BOOLEAN
is_array
,
va_list
*
args
,
WCHAR
*
buffer
,
ULONG
size
,
ULONG
*
retsize
)
{
return
RtlFormatMessageEx
(
src
,
width
,
ignore_inserts
,
ansi
,
is_array
,
args
,
buffer
,
size
,
retsize
,
0
);
...
...
@@ -1819,7 +1819,7 @@ NTSTATUS WINAPI RtlFormatMessage( const WCHAR *src, ULONG width, BOOLEAN ignore_
* RtlFormatMessageEx (NTDLL.@)
*/
NTSTATUS
WINAPI
RtlFormatMessageEx
(
const
WCHAR
*
src
,
ULONG
width
,
BOOLEAN
ignore_inserts
,
BOOLEAN
ansi
,
BOOLEAN
is_array
,
__ms_
va_list
*
args
,
BOOLEAN
ansi
,
BOOLEAN
is_array
,
va_list
*
args
,
WCHAR
*
buffer
,
ULONG
size
,
ULONG
*
retsize
,
ULONG
flags
)
{
static
const
WCHAR
spaceW
=
' '
;
...
...
dlls/ntdll/string.c
View file @
747b9753
...
...
@@ -1007,7 +1007,7 @@ static int char2digit( char c, int base )
}
static
int
vsscanf
(
const
char
*
str
,
const
char
*
format
,
__ms_
va_list
ap
)
static
int
vsscanf
(
const
char
*
str
,
const
char
*
format
,
va_list
ap
)
{
int
rd
=
0
,
consumed
=
0
;
int
nch
;
...
...
@@ -1445,10 +1445,10 @@ static int vsscanf( const char *str, const char *format, __ms_va_list ap)
int
WINAPIV
sscanf
(
const
char
*
str
,
const
char
*
format
,
...
)
{
int
ret
;
__ms_
va_list
valist
;
__ms_
va_start
(
valist
,
format
);
va_list
valist
;
va_start
(
valist
,
format
);
ret
=
vsscanf
(
str
,
format
,
valist
);
__ms_
va_end
(
valist
);
va_end
(
valist
);
return
ret
;
}
...
...
dlls/ntdll/tests/rtl.c
View file @
747b9753
...
...
@@ -3524,20 +3524,20 @@ static LONG CALLBACK test_dbg_print_except_handler( EXCEPTION_POINTERS *eptrs )
static
NTSTATUS
WINAPIV
test_vDbgPrintEx
(
ULONG
id
,
ULONG
level
,
const
char
*
fmt
,
...
)
{
NTSTATUS
status
;
__ms_
va_list
args
;
__ms_
va_start
(
args
,
fmt
);
va_list
args
;
va_start
(
args
,
fmt
);
status
=
vDbgPrintEx
(
id
,
level
,
fmt
,
args
);
__ms_
va_end
(
args
);
va_end
(
args
);
return
status
;
}
static
NTSTATUS
WINAPIV
test_vDbgPrintExWithPrefix
(
const
char
*
prefix
,
ULONG
id
,
ULONG
level
,
const
char
*
fmt
,
...
)
{
NTSTATUS
status
;
__ms_
va_list
args
;
__ms_
va_start
(
args
,
fmt
);
va_list
args
;
va_start
(
args
,
fmt
);
status
=
vDbgPrintExWithPrefix
(
prefix
,
id
,
level
,
fmt
,
args
);
__ms_
va_end
(
args
);
va_end
(
args
);
return
status
;
}
...
...
dlls/ntdll/tests/rtlstr.c
View file @
747b9753
...
...
@@ -72,7 +72,7 @@ static BOOLEAN (WINAPI *pRtlIsTextUnicode)(LPVOID, INT, INT *);
static
NTSTATUS
(
WINAPI
*
pRtlHashUnicodeString
)(
PCUNICODE_STRING
,
BOOLEAN
,
ULONG
,
ULONG
*
);
static
NTSTATUS
(
WINAPI
*
pRtlUnicodeToUTF8N
)(
CHAR
*
,
ULONG
,
ULONG
*
,
const
WCHAR
*
,
ULONG
);
static
NTSTATUS
(
WINAPI
*
pRtlUTF8ToUnicodeN
)(
WCHAR
*
,
ULONG
,
ULONG
*
,
const
CHAR
*
,
ULONG
);
static
NTSTATUS
(
WINAPI
*
pRtlFormatMessage
)(
const
WCHAR
*
,
ULONG
,
BOOLEAN
,
BOOLEAN
,
BOOLEAN
,
__ms_
va_list
*
,
LPWSTR
,
ULONG
,
ULONG
*
);
static
NTSTATUS
(
WINAPI
*
pRtlFormatMessage
)(
const
WCHAR
*
,
ULONG
,
BOOLEAN
,
BOOLEAN
,
BOOLEAN
,
va_list
*
,
LPWSTR
,
ULONG
,
ULONG
*
);
/*static VOID (WINAPI *pRtlFreeOemString)(PSTRING);*/
/*static VOID (WINAPI *pRtlCopyUnicodeString)(UNICODE_STRING *, const UNICODE_STRING *);*/
...
...
@@ -2614,27 +2614,27 @@ static void test_RtlUTF8ToUnicodeN(void)
static
NTSTATUS
WINAPIV
fmt
(
const
WCHAR
*
src
,
ULONG
width
,
BOOLEAN
ignore_inserts
,
BOOLEAN
ansi
,
WCHAR
*
buffer
,
ULONG
size
,
ULONG
*
retsize
,
...
)
{
__ms_
va_list
args
;
va_list
args
;
NTSTATUS
status
;
*
retsize
=
0xdeadbeef
;
__ms_
va_start
(
args
,
retsize
);
va_start
(
args
,
retsize
);
status
=
pRtlFormatMessage
(
src
,
width
,
ignore_inserts
,
ansi
,
FALSE
,
&
args
,
buffer
,
size
,
retsize
);
__ms_
va_end
(
args
);
va_end
(
args
);
return
status
;
}
static
void
WINAPIV
testfmt
(
const
WCHAR
*
src
,
const
WCHAR
*
expect
,
ULONG
width
,
BOOL
ansi
,
...
)
{
__ms_
va_list
args
;
va_list
args
;
NTSTATUS
status
;
WCHAR
buffer
[
128
];
ULONG
size
=
0xdeadbeef
;
memset
(
buffer
,
0xcc
,
sizeof
(
buffer
)
);
__ms_
va_start
(
args
,
ansi
);
va_start
(
args
,
ansi
);
status
=
pRtlFormatMessage
(
src
,
width
,
FALSE
,
ansi
,
FALSE
,
&
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
__ms_
va_end
(
args
);
va_end
(
args
);
ok
(
!
status
,
"%s: failed %x
\n
"
,
debugstr_w
(
src
),
status
);
ok
(
!
lstrcmpW
(
buffer
,
expect
),
"%s: got %s expected %s
\n
"
,
debugstr_w
(
src
),
debugstr_w
(
buffer
),
debugstr_w
(
expect
)
);
...
...
@@ -2689,11 +2689,11 @@ static void test_RtlFormatMessage(void)
ULONG_PTR
args
[]
=
{
19
,
17
,
15
,
13
,
11
,
9
,
7
};
memset
(
buffer
,
0xcc
,
sizeof
(
buffer
)
);
status
=
pRtlFormatMessage
(
L"%2!*.*I64x! %1!u! %4!u! %2!u!"
,
0
,
FALSE
,
FALSE
,
TRUE
,
(
__ms_
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
(
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
ok
(
!
lstrcmpW
(
buffer
,
L" 00000000000000d 19 13 17"
),
"got %s
\n
"
,
wine_dbgstr_w
(
buffer
)
);
memset
(
buffer
,
0xcc
,
sizeof
(
buffer
)
);
status
=
pRtlFormatMessage
(
L"%1!I64u! %2!u! %4!.*I64x! %5!I64u!"
,
0
,
FALSE
,
FALSE
,
TRUE
,
(
__ms_
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
(
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
ok
(
!
lstrcmpW
(
buffer
,
L"19 17 000000000000b 11"
),
"got %s
\n
"
,
wine_dbgstr_w
(
buffer
)
);
}
#else
...
...
@@ -2712,11 +2712,11 @@ static void test_RtlFormatMessage(void)
ULONG_PTR
args
[]
=
{
19
,
17
,
15
,
13
,
11
,
9
,
7
};
memset
(
buffer
,
0xcc
,
sizeof
(
buffer
)
);
status
=
pRtlFormatMessage
(
L"%2!*.*I64x! %1!u! %4!u! %2!u!"
,
0
,
FALSE
,
FALSE
,
TRUE
,
(
__ms_
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
(
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
ok
(
!
lstrcmpW
(
buffer
,
L" d0000000f 19 13 17"
),
"got %s
\n
"
,
wine_dbgstr_w
(
buffer
)
);
memset
(
buffer
,
0xcc
,
sizeof
(
buffer
)
);
status
=
pRtlFormatMessage
(
L"%1!I64u! %2!u! %4!.*I64x! %5!I64u!"
,
0
,
FALSE
,
FALSE
,
TRUE
,
(
__ms_
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
(
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
ok
(
!
lstrcmpW
(
buffer
,
L"19 17 0000b00000000 11"
),
"got %s
\n
"
,
wine_dbgstr_w
(
buffer
)
);
}
}
...
...
@@ -2775,11 +2775,11 @@ static void test_RtlFormatMessage(void)
{
ULONG_PTR
args
[]
=
{
6
,
4
,
2
,
5
,
3
,
1
};
memset
(
buffer
,
0xcc
,
sizeof
(
buffer
)
);
status
=
pRtlFormatMessage
(
L"%1!*.*u!,%1!*.*u!"
,
0
,
FALSE
,
FALSE
,
TRUE
,
(
__ms_
va_list
*
)
args
,
status
=
pRtlFormatMessage
(
L"%1!*.*u!,%1!*.*u!"
,
0
,
FALSE
,
FALSE
,
TRUE
,
(
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
ok
(
!
lstrcmpW
(
buffer
,
L" 0002, 00003"
),
"got %s
\n
"
,
wine_dbgstr_w
(
buffer
)
);
memset
(
buffer
,
0xcc
,
sizeof
(
buffer
)
);
status
=
pRtlFormatMessage
(
L"%1!*.*u!,%4!*.*u!"
,
0
,
FALSE
,
FALSE
,
TRUE
,
(
__ms_
va_list
*
)
args
,
status
=
pRtlFormatMessage
(
L"%1!*.*u!,%4!*.*u!"
,
0
,
FALSE
,
FALSE
,
TRUE
,
(
va_list
*
)
args
,
buffer
,
sizeof
(
buffer
),
&
size
);
ok
(
!
lstrcmpW
(
buffer
,
L" 0002, 001"
),
"got %s
\n
"
,
wine_dbgstr_w
(
buffer
)
);
}
...
...
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