Leaked source code of windows server 2003
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
//+-------------------------------------------------------------------------
//
// Microsoft Windows
//
// Copyright (C) Microsoft Corporation, 1996 - 1999
//
// File: dll.cpp
//
// Core entry points for the DLL
//
//--------------------------------------------------------------------------
#include "aclpriv.h"
/*----------------------------------------------------------------------------
/ Globals /----------------------------------------------------------------------------*/
HINSTANCE hModule = NULL; HINSTANCE g_hGetUserLib = NULL;
UINT UM_SIDLOOKUPCOMPLETE = 0; UINT g_cfDsSelectionList = 0; UINT g_cfSidInfoList = 0;
/*-----------------------------------------------------------------------------
/ DllMain / ------- / Main entry point. We are passed reason codes and assored other / information when loaded or closed down. / / In: / hInstance = our instance handle / dwReason = reason code / pReserved = depends on the reason code. / / Out: / - /----------------------------------------------------------------------------*/ STDAPI_(BOOL) DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID /*pReserved*/) { switch (dwReason) { case DLL_PROCESS_ATTACH: hModule = hInstance; DebugProcessAttach(); TraceSetMaskFromRegKey(HKEY_LOCAL_MACHINE, TEXT("Software\\Microsoft\\Windows NT\\CurrentVersion\\AclUI")); #ifndef DEBUG
DisableThreadLibraryCalls(hInstance); #endif
SHFusionInitializeFromModuleID(hInstance, SHFUSION_DEFAULT_RESOURCE_ID); RegisterCheckListWndClass(); LinkWindow_RegisterClass();
UM_SIDLOOKUPCOMPLETE = RegisterWindowMessage(TEXT("ACLUI SID Lookup Complete")); g_cfDsSelectionList = RegisterClipboardFormat(CFSTR_DSOP_DS_SELECTION_LIST); g_cfSidInfoList = RegisterClipboardFormat(CFSTR_ACLUI_SID_INFO_LIST); break;
case DLL_PROCESS_DETACH: FreeSidCache(); if (g_hGetUserLib) FreeLibrary(g_hGetUserLib); SHFusionUninitialize(); LinkWindow_UnregisterClass(hInstance); DebugProcessDetach(); break;
case DLL_THREAD_DETACH: DebugThreadDetach(); break; }
return TRUE; }
|