1 #ifndef TLSM_C_INCLUDED
2 #define TLSM_C_INCLUDED
3 
4 #ifdef WIN32
5 #else /* WIN32 */
6 #include <curl/curl.h>
7 #endif /* WIN32 */
8 
9 #include "mcontext.h"
10 #include "socketpuller.h"
11 #include "stringlist.h"
12 
13 typedef struct _TlsM TlsM;
14 
15 struct _TlsM {
16     /* private */
17 #ifdef WIN32
18 #else /* WIN32 */
19     CURL            *Departure;
20 #endif /* WIN32 */
21 
22     StringList      ServiceList;
23     const char      **Services;
24 
25     SOCKET          Incoming;
26     Address_Type    IncomingAddr;
27     SocketPuller    Puller;
28 
29     ModuleContext   Context;
30 
31     ThreadHandle    WorkThread;
32 
33     /* public */
34     int (*Send)(TlsM *m,
35                 IHeader *h, /* Entity followed */
36                 int BufferLength
37                 );
38 };
39 
40 int TlsM_Init(TlsM *m, const char *Services);
41 
42 #endif // TLSM_C_INCLUDED
43