print request path
This commit is contained in:
1 parent
ed71a635c9
commit
afa63acf85
4 files changed
+4
No files matched your search
@@ -87,6 +87,7 @@ void *handle_request(void *param) {
|
|||||||
close(ssl);
|
close(ssl);
|
||||||
pthread_exit(0);
|
pthread_exit(0);
|
||||||
}
|
}
|
||||||
|
printf("%s %s %s\n", path, method, proto);
|
||||||
|
|
||||||
if (strcmp(method, "GET")) {
|
if (strcmp(method, "GET")) {
|
||||||
send_response(ssl, "405 Method Not Allowed", "text/plain", "Method Not Allowed", 18);
|
send_response(ssl, "405 Method Not Allowed", "text/plain", "Method Not Allowed", 18);
|
||||||
|
|||||||
@@ -77,6 +77,7 @@ static void handle_request(int ssl, char *req) {
|
|||||||
send_response(ssl, "400 Bad Request", "text/plain", "Bad Request", 11);
|
send_response(ssl, "400 Bad Request", "text/plain", "Bad Request", 11);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
printf("%s %s %s\n", path, method, proto);
|
||||||
|
|
||||||
if (strcmp(method, "GET")) {
|
if (strcmp(method, "GET")) {
|
||||||
send_response(ssl, "405 Method Not Allowed", "text/plain", "Method Not Allowed", 18);
|
send_response(ssl, "405 Method Not Allowed", "text/plain", "Method Not Allowed", 18);
|
||||||
|
|||||||
@@ -93,6 +93,7 @@ void *handle_request(void *param) {
|
|||||||
close(client_sock);
|
close(client_sock);
|
||||||
pthread_exit(0);
|
pthread_exit(0);
|
||||||
}
|
}
|
||||||
|
printf("%s %s %s\n", path, method, proto);
|
||||||
|
|
||||||
if (strcmp(method, "GET")) {
|
if (strcmp(method, "GET")) {
|
||||||
send_response(ssl, "405 Method Not Allowed", "text/plain", "Method Not Allowed", 18);
|
send_response(ssl, "405 Method Not Allowed", "text/plain", "Method Not Allowed", 18);
|
||||||
|
|||||||
@@ -79,6 +79,7 @@ static void handle_request(SSL *ssl, char *req) {
|
|||||||
send_response(ssl, "400 Bad Request", "text/plain", "Bad Request", 11);
|
send_response(ssl, "400 Bad Request", "text/plain", "Bad Request", 11);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
printf("%s %s %s\n", path, method, proto);
|
||||||
|
|
||||||
if (strcmp(method, "GET")) {
|
if (strcmp(method, "GET")) {
|
||||||
send_response(ssl, "405 Method Not Allowed", "text/plain", "Method Not Allowed", 18);
|
send_response(ssl, "405 Method Not Allowed", "text/plain", "Method Not Allowed", 18);
|
||||||
|
|||||||
Reference in new issue
Block a user