-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.cpp
28 lines (22 loc) · 1020 Bytes
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/*=============================================================================
Created by NxtChg ([email protected]), 2017. License: Public Domain.
=============================================================================*/
#include "include/chttp.h"
#include "src/common.h"
#include "src/server.h"
#pragma comment(linker, "/comment:\" [built on " __DATE__ " at " __TIME__ " by NxtChg] \"")
//_____________________________________________________________________________
CHTTP_API(int) chttp_start(char *address, chttp_cb cb){ return server.start(address, cb); }
CHTTP_API(void) chttp_tick(){ server.tick(); }
CHTTP_API(void) chttp_stop(){ server.stop(); }
//_____________________________________________________________________________
BOOL APIENTRY DllMain(HMODULE h, DWORD reason, LPVOID reserved)
{
reserved = 0; // make compiler happy
switch(reason)
{
case DLL_PROCESS_ATTACH: DisableThreadLibraryCalls(h); break;
case DLL_PROCESS_DETACH: break;
}
return TRUE;
}