mirror of https://github.com/Cisco-Talos/clamav
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.
33 lines
636 B
33 lines
636 B
![]()
16 years ago
|
/* just a draft for now */
|
||
|
|
||
|
#if HAVE_CONFIG_H
|
||
|
#include "clamav-config.h"
|
||
|
#endif
|
||
|
|
||
|
#include "pthread.h"
|
||
|
|
||
|
BOOL APIENTRY DllMain(HMODULE hm, DWORD why, LPVOID rsrv) {
|
||
|
WSADATA wsa;
|
||
|
switch (why) {
|
||
|
case DLL_PROCESS_ATTACH:
|
||
|
if(WSAStartup(MAKEWORD(2,2), &wsa))
|
||
|
return FALSE;
|
||
|
return pthread_win32_process_attach_np();
|
||
|
break;
|
||
|
|
||
|
case DLL_THREAD_ATTACH:
|
||
|
return pthread_win32_thread_attach_np ();
|
||
|
break;
|
||
|
|
||
|
case DLL_THREAD_DETACH:
|
||
|
return pthread_win32_thread_detach_np ();
|
||
|
break;
|
||
|
|
||
|
case DLL_PROCESS_DETACH:
|
||
|
WSACleanup();
|
||
|
pthread_win32_thread_detach_np ();
|
||
|
return pthread_win32_process_detach_np ();
|
||
|
break;
|
||
|
}
|
||
|
}
|