ReactOS  0.4.15-dev-2344-g8ddbfde
_vscprintf.c File Reference
#include <apitest.h>
#include <stdio.h>
#include <tchar.h>
#include <errno.h>
Include dependency graph for _vscprintf.c:

Go to the source code of this file.


static void call_varargs (int expected_ret, LPCSTR formatString,...)
 START_TEST (_vscprintf)

Function Documentation

◆ call_varargs()

static void call_varargs ( int  expected_ret,
LPCSTR  formatString,

Definition at line 13 of file _vscprintf.c.

14 {
15  va_list args;
16  int ret;
17  /* Test the basic functionality */
18  va_start(args, formatString);
19  ret = _vscprintf(formatString, args);
20  va_end(args);
21  ok(expected_ret == ret, "Test failed: expected %i, got %i.\n", expected_ret, ret);
22 }
#define args
Definition: format.c:66
Definition: match.c:390
#define va_end(ap)
Definition: acmsvcex.h:90
char * va_list
Definition: acmsvcex.h:78
va_start(ap, x)
int ret
int __cdecl _vscprintf(const char *format, va_list argptr)
Definition: _vscprintf.c:15
#define ok(value,...)
Definition: atltest.h:57

Referenced by START_TEST().


START_TEST ( _vscprintf  )

Definition at line 24 of file _vscprintf.c.

25 {
26  /* Here you can mix wide and ANSI strings */
27  call_varargs(12, "%S world!", L"hello");
28  call_varargs(12, "%s world!", "hello");
29  call_varargs(11, "%u cookies", 100);
30  /* Do not test NULL argument. That is verified to SEGV on a */
31  /* release-build with VC10 and MS' msvcrt. */
32 }
static void call_varargs(int expected_ret, LPCSTR formatString,...)
Definition: _vscprintf.c:13
static const WCHAR L[]
Definition: oid.c:1250