Commit c6b852e3 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

msvcrt: Use more public declarations in exe entry points.

parent c15733de
......@@ -25,15 +25,11 @@
#ifdef __MINGW32__
#include <stdarg.h>
#include <process.h>
#include "windef.h"
#include "winbase.h"
/* FIXME: Use msvcrt headers once we move to PE file */
void __cdecl exit(int);
void __cdecl __getmainargs(int *, char ***, char ***, int, int *);
void __cdecl __set_app_type(int);
int __cdecl main(int argc, char **argv, char **env);
static const IMAGE_NT_HEADERS *get_nt_header( void )
......@@ -48,7 +44,7 @@ int __cdecl mainCRTStartup(void)
char **argv, **env;
__getmainargs(&argc, &argv, &env, 0, &new_mode);
__set_app_type(get_nt_header()->OptionalHeader.Subsystem == IMAGE_SUBSYSTEM_WINDOWS_GUI ? 2 : 1);
_set_app_type(get_nt_header()->OptionalHeader.Subsystem == IMAGE_SUBSYSTEM_WINDOWS_GUI ? _crt_gui_app : _crt_console_app);
ret = main(argc, argv, env);
......
......@@ -25,15 +25,11 @@
#ifdef __MINGW32__
#include <stdarg.h>
#include <process.h>
#include "windef.h"
#include "winbase.h"
/* FIXME: Use msvcrt headers once we move to PE file */
void __cdecl exit(int);
void __cdecl __wgetmainargs(int *, WCHAR ***, WCHAR ***, int, int *);
void __cdecl __set_app_type(int);
int __cdecl wmain(int argc, WCHAR **argv, WCHAR **env);
static const IMAGE_NT_HEADERS *get_nt_header( void )
......@@ -48,7 +44,7 @@ int __cdecl wmainCRTStartup(void)
WCHAR **argv, **env;
__wgetmainargs(&argc, &argv, &env, 0, &new_mode);
__set_app_type(get_nt_header()->OptionalHeader.Subsystem == IMAGE_SUBSYSTEM_WINDOWS_GUI ? 2 : 1);
_set_app_type(get_nt_header()->OptionalHeader.Subsystem == IMAGE_SUBSYSTEM_WINDOWS_GUI ? _crt_gui_app : _crt_console_app);
ret = wmain(argc, argv, env);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment