_cexit should call the atexit functions.

This commit is contained in:
Alexandre Julliard 2005-10-21 15:55:20 +00:00
parent c0b79e0b05
commit bb648917b6
1 changed files with 4 additions and 4 deletions

View File

@ -190,7 +190,9 @@ void MSVCRT__c_exit(void)
void MSVCRT__cexit(void) void MSVCRT__cexit(void)
{ {
TRACE("(void)\n"); TRACE("(void)\n");
/* All cleanup is done on DLL detach; Return to caller */ LOCK_EXIT;
__MSVCRT__call_atexit();
UNLOCK_EXIT;
} }
/********************************************************************* /*********************************************************************
@ -233,9 +235,7 @@ MSVCRT__onexit_t MSVCRT__onexit(MSVCRT__onexit_t func)
void MSVCRT_exit(int exitcode) void MSVCRT_exit(int exitcode)
{ {
TRACE("(%d)\n",exitcode); TRACE("(%d)\n",exitcode);
LOCK_EXIT; MSVCRT__cexit();
__MSVCRT__call_atexit();
UNLOCK_EXIT;
ExitProcess(exitcode); ExitProcess(exitcode);
} }