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.

23 lines
704 B

  1. #include <windows.h>
  2. #include "unknwn.h"
  3. extern HRESULT WINAPI DirectPlay8Create( const GUID * pcIID, void **ppvInterface, IUnknown *pUnknown);
  4. STDAPI_(BOOL) DllMain( HANDLE hModule,
  5. DWORD ul_reason_for_call,
  6. LPVOID lpReserved
  7. )
  8. {
  9. #ifdef WIN95
  10. //
  11. // This is a fix to ensure that dpnet.dll gets loaded so GetProcAddress() doesn't fail on Win9x for
  12. // legacy calls to DirectPlay8LobbyCreate(). This code should never get executed, nor get optimized out.
  13. //
  14. if ((hModule == NULL) && (ul_reason_for_call == 0x12345678) && (lpReserved == NULL))
  15. {
  16. DirectPlay8Create( NULL, NULL, NULL );
  17. }
  18. #endif // WIN95
  19. return TRUE;
  20. }