Changeset 21302 for trunk/src/kernel32/initkernel32.cpp
- Timestamp:
- Jun 18, 2009, 11:53:26 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kernel32/initkernel32.cpp
r10606 r21302 60 60 #include <stats.h> 61 61 #include <heapshared.h> 62 #include < heapstring.h>62 #include <_ras.h> 63 63 64 64 #define DBG_LOCALLOG DBG_initterm … … 71 71 extern DWORD kernel32_PEResTab; 72 72 } 73 74 extern PFN pfnImSetMsgQueueProperty;75 73 76 74 ULONG flAllocMem = 0; /* flag to optimize DosAllocMem to use all the memory on SMP machines */ … … 81 79 BOOL fInit = FALSE; 82 80 BOOL fWin32k = FALSE; 83 HMODULE imHandle = 0;84 char szModName[ 256 ] = "";85 81 86 82 /****************************************************************************/ … … 113 109 case 0 : 114 110 { 111 // This always must be the first thing to do. 112 RasInitialize (hModule); 113 #ifdef RAS 114 extern void rasInitVirtual (void); 115 rasInitVirtual (); 116 #endif 117 115 118 ParseLogStatusKERNEL32(); 116 119 … … 221 224 CODEPAGE_Init(); 222 225 223 if( IsDBCSEnv() && DosLoadModule( szModName, sizeof( szModName ), "OS2IM.DLL", &imHandle ) == 0 )224 DosQueryProcAddr( imHandle, 140, NULL, &pfnImSetMsgQueueProperty );225 226 226 InitSystemInfo(ulSysinfo); 227 227 //Set up environment as found in NT … … 237 237 SetProcessAffinityMask(GetCurrentProcess(), dwSystemAffinityMask); 238 238 239 //Activate current timezone information 240 TIME_ZONE_INFORMATION tzone; 241 GetTimeZoneInformation(&tzone); 242 SetTimeZoneInformation(&tzone); 243 239 244 //Set default paths for PE & NE loaders 240 245 InitLoaders(); 246 247 RasEntry (RAS_EVENT_Kernel32InitComplete, &dllHandle, sizeof (dllHandle)); 248 241 249 break; 242 250 } … … 264 272 dprintf(("kernel32 exit %d\n", ulReason)); 265 273 266 if( IsDBCSEnv() && imHandle )267 DosFreeModule( imHandle );268 269 274 //Flush and delete all open memory mapped files 270 275 Win32MemMap::deleteAll(); 271 276 WinExe = NULL; 277 278 FinalizeMemMaps(); 272 279 273 280 WriteOutProfiles(); … … 281 288 282 289 HMTerminate(); /* shutdown handlemanager */ 290 291 #ifdef DEBUG 292 extern void printCriticalSectionStatistic (void); 293 printCriticalSectionStatistic (); 294 #endif 283 295 284 296 #if defined(DEBUG) && defined(__IBMCPP__) && __IBMCPP__ == 300 … … 298 310 //NOTE: Must be done after DestroyTIB 299 311 ClosePrivateLogFiles(); 312 313 #ifndef DEBUG 314 //if we do a dump of the shared heap, then we'll need the logging facility 315 //for a little while longer 300 316 CloseLogFile(); 317 #endif 301 318 302 319 /* … … 305 322 libWin32kSetEnvironment(NULL, 0, 0); 306 323 libWin32kTerm(); 324 325 RasUninitialize (); 326 307 327 return ; 308 328 }
Note:
See TracChangeset
for help on using the changeset viewer.