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
f8de2ebb
Commit
f8de2ebb
authored
Jan 02, 2009
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msvcrt: Convert all the scanf functions to use MS ABI varargs.
parent
07ca8f4f
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
26 deletions
+26
-26
scanf.c
dlls/msvcrt/scanf.c
+21
-21
scanf.h
dlls/msvcrt/scanf.h
+5
-5
No files found.
dlls/msvcrt/scanf.c
View file @
f8de2ebb
...
...
@@ -93,12 +93,12 @@ static int wchar2digit(MSVCRT_wchar_t c, int base) {
*/
int
CDECL
MSVCRT_fscanf
(
MSVCRT_FILE
*
file
,
const
char
*
format
,
...)
{
va_list
valist
;
__ms_
va_list
valist
;
int
res
;
va_start
(
valist
,
format
);
__ms_
va_start
(
valist
,
format
);
res
=
MSVCRT_vfscanf
(
file
,
format
,
valist
);
va_end
(
valist
);
__ms_
va_end
(
valist
);
return
res
;
}
...
...
@@ -107,12 +107,12 @@ int CDECL MSVCRT_fscanf(MSVCRT_FILE *file, const char *format, ...)
*/
int
CDECL
MSVCRT_scanf
(
const
char
*
format
,
...)
{
va_list
valist
;
__ms_
va_list
valist
;
int
res
;
va_start
(
valist
,
format
);
__ms_
va_start
(
valist
,
format
);
res
=
MSVCRT_vfscanf
(
MSVCRT_stdin
,
format
,
valist
);
va_end
(
valist
);
__ms_
va_end
(
valist
);
return
res
;
}
...
...
@@ -121,12 +121,12 @@ int CDECL MSVCRT_scanf(const char *format, ...)
*/
int
CDECL
MSVCRT_fwscanf
(
MSVCRT_FILE
*
file
,
const
MSVCRT_wchar_t
*
format
,
...)
{
va_list
valist
;
__ms_
va_list
valist
;
int
res
;
va_start
(
valist
,
format
);
__ms_
va_start
(
valist
,
format
);
res
=
MSVCRT_vfwscanf
(
file
,
format
,
valist
);
va_end
(
valist
);
__ms_
va_end
(
valist
);
return
res
;
}
...
...
@@ -136,12 +136,12 @@ int CDECL MSVCRT_fwscanf(MSVCRT_FILE *file, const MSVCRT_wchar_t *format, ...)
*/
int
CDECL
MSVCRT_wscanf
(
const
MSVCRT_wchar_t
*
format
,
...)
{
va_list
valist
;
__ms_
va_list
valist
;
int
res
;
va_start
(
valist
,
format
);
__ms_
va_start
(
valist
,
format
);
res
=
MSVCRT_vfwscanf
(
MSVCRT_stdin
,
format
,
valist
);
va_end
(
valist
);
__ms_
va_end
(
valist
);
return
res
;
}
...
...
@@ -151,12 +151,12 @@ int CDECL MSVCRT_wscanf(const MSVCRT_wchar_t *format, ...)
*/
int
CDECL
MSVCRT_sscanf
(
const
char
*
str
,
const
char
*
format
,
...)
{
va_list
valist
;
__ms_
va_list
valist
;
int
res
;
va_start
(
valist
,
format
);
__ms_
va_start
(
valist
,
format
);
res
=
MSVCRT_vsscanf
(
str
,
format
,
valist
);
va_end
(
valist
);
__ms_
va_end
(
valist
);
return
res
;
}
...
...
@@ -166,12 +166,12 @@ int CDECL MSVCRT_sscanf(const char *str, const char *format, ...)
*/
int
CDECL
MSVCRT_swscanf
(
const
MSVCRT_wchar_t
*
str
,
const
MSVCRT_wchar_t
*
format
,
...)
{
va_list
valist
;
__ms_
va_list
valist
;
int
res
;
va_start
(
valist
,
format
);
__ms_
va_start
(
valist
,
format
);
res
=
MSVCRT_vswscanf
(
str
,
format
,
valist
);
va_end
(
valist
);
__ms_
va_end
(
valist
);
return
res
;
}
...
...
@@ -181,11 +181,11 @@ int CDECL MSVCRT_swscanf(const MSVCRT_wchar_t *str, const MSVCRT_wchar_t *format
*/
int
CDECL
_cscanf
(
const
char
*
format
,
...)
{
va_list
valist
;
__ms_
va_list
valist
;
int
res
;
va_start
(
valist
,
format
);
__ms_
va_start
(
valist
,
format
);
res
=
MSVCRT_vcscanf
(
format
,
valist
);
va_end
(
valist
);
__ms_
va_end
(
valist
);
return
res
;
}
dlls/msvcrt/scanf.h
View file @
f8de2ebb
...
...
@@ -48,7 +48,7 @@
#ifdef CONSOLE
#define _GETC_(file) (consumed++, _getch())
#define _UNGETC_(nch, file) do { _ungetch(nch); consumed--; } while(0)
#define _FUNCTION_ static int MSVCRT_vcscanf(const char *format, va_list ap)
#define _FUNCTION_ static int MSVCRT_vcscanf(const char *format,
__ms_
va_list ap)
#else
#ifdef STRING
#undef _EOF_
...
...
@@ -56,19 +56,19 @@
#define _GETC_(file) (consumed++, *file++)
#define _UNGETC_(nch, file) do { file--; consumed--; } while(0)
#ifdef WIDE_SCANF
#define _FUNCTION_ static int MSVCRT_vswscanf(const MSVCRT_wchar_t *file, const MSVCRT_wchar_t *format, va_list ap)
#define _FUNCTION_ static int MSVCRT_vswscanf(const MSVCRT_wchar_t *file, const MSVCRT_wchar_t *format,
__ms_
va_list ap)
#else
/* WIDE_SCANF */
#define _FUNCTION_ static int MSVCRT_vsscanf(const char *file, const char *format, va_list ap)
#define _FUNCTION_ static int MSVCRT_vsscanf(const char *file, const char *format,
__ms_
va_list ap)
#endif
/* WIDE_SCANF */
#else
/* STRING */
#ifdef WIDE_SCANF
#define _GETC_(file) (consumed++, MSVCRT_fgetwc(file))
#define _UNGETC_(nch, file) do { MSVCRT_ungetwc(nch, file); consumed--; } while(0)
#define _FUNCTION_ static int MSVCRT_vfwscanf(MSVCRT_FILE* file, const MSVCRT_wchar_t *format, va_list ap)
#define _FUNCTION_ static int MSVCRT_vfwscanf(MSVCRT_FILE* file, const MSVCRT_wchar_t *format,
__ms_
va_list ap)
#else
/* WIDE_SCANF */
#define _GETC_(file) (consumed++, MSVCRT_fgetc(file))
#define _UNGETC_(nch, file) do { MSVCRT_ungetc(nch, file); consumed--; } while(0)
#define _FUNCTION_ static int MSVCRT_vfscanf(MSVCRT_FILE* file, const char *format, va_list ap)
#define _FUNCTION_ static int MSVCRT_vfscanf(MSVCRT_FILE* file, const char *format,
__ms_
va_list ap)
#endif
/* WIDE_SCANF */
#endif
/* STRING */
#endif
/* CONSOLE */
...
...
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