X-Git-Url: http://git.jankratochvil.net/?p=reactos.git;a=blobdiff_plain;f=lib%2Fcrtdll%2Fmisc%2Finit.c;fp=lib%2Fcrtdll%2Fmisc%2Finit.c;h=71cd1449cd2dbc6277fb8f09f7f8f294016dc4f4;hp=2ee3da1f65be42c3b9ed7bc79b5158ae22b32a32;hb=e3ed2d773259cc445c7ff8181ebd934931365328;hpb=d378c68f5a9bb25c9e671dacd482d2e25d211df3 diff --git a/lib/crtdll/misc/init.c b/lib/crtdll/misc/init.c index 2ee3da1..71cd144 100644 --- a/lib/crtdll/misc/init.c +++ b/lib/crtdll/misc/init.c @@ -29,8 +29,8 @@ * Access to a standard 'main'-like argument count and list. Also included * is a table of environment variables. */ -int _argc = 0; -char** _argv = 0; +int _argc = 0; +char** _argv = 0; /* NOTE: Thanks to Pedro A. Aranda Gutiirrez for pointing * this out to me. GetMainArgs (used below) takes a fourth argument @@ -44,13 +44,9 @@ char** _argv = 0; * defining _CRT_glob and setting it to zero, like this: * int _CRT_glob = 0; */ -extern int _CRT_glob; +extern int _CRT_glob; -#ifdef __MSVCRT__ -extern void __getmainargs(int *, char***, char***, int); -#else extern void __GetMainArgs(int *, char***, char***, int); -#endif /* * Initialize the _argc, _argv and environ variables. @@ -58,18 +54,18 @@ extern void __GetMainArgs(int *, char***, char***, int); static void _mingw32_init_mainargs (void) { - /* The environ variable is provided directly in stdlib.h through - * a dll function call. */ - char** dummy_environ; + /* The environ variable is provided directly in stdlib.h through + * a dll function call. */ + char** dummy_environ; - /* - * Microsoft's runtime provides a function for doing just that. - */ -#ifdef __MSVCRT__ - (void) __getmainargs(&_argc, &_argv, &dummy_environ, _CRT_glob); + /* + * Microsoft's runtime provides a function for doing just that. + */ +#ifdef _MSVCRT_LIB_ + (void) __getmainargs(&_argc, &_argv, &dummy_environ, _CRT_glob); #else - /* CRTDLL version */ - (void) __GetMainArgs(&_argc, &_argv, &dummy_environ, _CRT_glob); + /* CRTDLL version */ + (void) __GetMainArgs(&_argc, &_argv, &dummy_environ, _CRT_glob); #endif }