-
Notifications
You must be signed in to change notification settings - Fork 0
/
ot_http.h
30 lines (23 loc) · 827 Bytes
/
ot_http.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
/* This software was written by Dirk Engling <[email protected]>
It is considered beerware. Prost. Skol. Cheers or whatever.
$id$ */
#ifndef OT_HTTP_H__
#define OT_HTTP_H__
typedef enum {
STRUCT_HTTP_FLAG_WAITINGFORTASK = 1,
STRUCT_HTTP_FLAG_GZIP = 2,
STRUCT_HTTP_FLAG_BZIP2 = 4
} STRUCT_HTTP_FLAG;
struct http_data {
array request;
io_batch *batch;
size_t batches;
ot_ip6 ip;
STRUCT_HTTP_FLAG flag;
};
ssize_t http_handle_request( const int64 s, struct ot_workstruct *ws );
ssize_t http_sendiovecdata( const int64 s, struct ot_workstruct *ws, int iovec_entries, struct iovec *iovector );
ssize_t http_issue_error( const int64 s, struct ot_workstruct *ws, int code );
extern char *g_stats_path;
extern ssize_t g_stats_path_len;
#endif