Fix MSVC global constructor initialization.

svn path=/trunk/; revision=64821
This commit is contained in:
Timo Kreuzer 2014-10-19 10:27:22 +00:00
parent a4a867f83a
commit 74cb166477

View file

@ -20,6 +20,12 @@
#error Unsupported platform
#endif
/*
* Initializer / constructor handling
* see http://msdn.microsoft.com/en-us/library/bb918180.aspx
* Destructors are registered from the initializers using atexit()
*/
extern _PVFV __xi_a[];
extern _PVFV __xi_z[];
extern _PVFV __xc_a[];
@ -34,7 +40,7 @@ __do_xtors(
_PVFV *current;
for (current = start; current < end; current++)
{
if (*current != NULL);
if (*current != NULL)
(*current)();
}
}
@ -49,12 +55,6 @@ int __mingw_init_ehandler(void)
return 1;
}
void
__do_global_dtors(void)
{
}
void
__do_global_ctors(void)
{