26 * POSSIBILITY OF SUCH DAMAGE. |
26 * POSSIBILITY OF SUCH DAMAGE. |
27 */ |
27 */ |
28 |
28 |
29 #include "protocol.h" |
29 #include "protocol.h" |
30 |
30 |
|
31 #include "session.h" |
|
32 #include "httplistener.h" |
|
33 #include "request.h" |
|
34 |
31 #include "../util/pblock.h" |
35 #include "../util/pblock.h" |
32 #include "../util/pool.h" |
36 #include "../util/pool.h" |
33 #include "session.h" |
|
34 #include "../util/io.h" |
37 #include "../util/io.h" |
35 #include "../util/util.h" |
38 #include "../util/util.h" |
36 #include "../util/strbuf.h" |
39 #include "../util/strbuf.h" |
37 |
40 |
|
41 #define HTTP_SCHEME "http" |
|
42 #define HTTPS_SCHEME "https" |
38 |
43 |
39 void protocol_status(Session *sn, Request *rq, int n, const char *m) { |
44 void protocol_status(Session *sn, Request *rq, int n, const char *m) { |
40 rq->status_num = n; |
45 rq->status_num = n; |
41 |
46 |
42 const char *msg = m ? m : protocol_status_message(n); |
47 const char *msg = m ? m : protocol_status_message(n); |