-
Notifications
You must be signed in to change notification settings - Fork 1
/
tapi_logging.h
65 lines (47 loc) · 1001 Bytes
/
tapi_logging.h
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
/*++
Copyright 2009-2012 IPcom GmbH
Copyright 1995 - 2000 Microsoft Corporation
Module Name: tapi_logging.h
These functions are used for logging from a TSP.
--*/
#pragma once
#include <windows.h>
#define LOGGING
#define LOGFILENAME "c:\\httptapi.log"
void setLogLevel(DWORD);
DWORD getLogLevel();
#ifdef LOGGING
typedef struct _FUNC_PARAM
{
char *lpszVal;
DWORD dwVal;
} FUNC_PARAM, *PFUNC_PARAM;
#endif
typedef struct _FUNC_INFO
{
#ifdef LOGGING
char *lpszFuncName;
DWORD dwNumParams;
PFUNC_PARAM aParams;
#endif
LONG lResult;
} FUNC_INFO, *PFUNC_INFO;
#ifdef LOGGING
void CDECL DebugOutput(
DWORD dwLevel,
LPCSTR lpszFormat,
...
);
#define LOG(arg) DebugOutput arg
LONG PASCAL Epilog(
PFUNC_INFO pInfo,
LONG lResult
);
void PASCAL Prolog(
PFUNC_INFO pInfo
);
#else
#define LOG(arg)
#define Epilog(pAsyncRequestInfo, lResult) (lResult)
#define Prolog(pAsyncRequestInfo)
#endif