summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adam@chlipala.net>2010-11-20 09:48:03 -0500
committerGravatar Adam Chlipala <adam@chlipala.net>2010-11-20 09:48:03 -0500
commitaa6e63371697ca158bd9b1fe9e68ecbd59fbf72a (patch)
tree9fefe5208e41e51cc58656d1f08d1adf9f08c7a8 /src
parent4b56d9e4622c002ad3db0c8549a503170e698434 (diff)
In FastCGI, signal 304 with a header, not the usual HTTP/1.1 line
Diffstat (limited to 'src')
-rw-r--r--src/c/cgi.c2
-rw-r--r--src/c/fastcgi.c2
-rw-r--r--src/c/http.c2
-rw-r--r--src/c/request.c2
-rw-r--r--src/cjr_print.sml2
5 files changed, 8 insertions, 2 deletions
diff --git a/src/c/cgi.c b/src/c/cgi.c
index fe7dc564..50d64f58 100644
--- a/src/c/cgi.c
+++ b/src/c/cgi.c
@@ -137,3 +137,5 @@ void uw_do_expunge(uw_context ctx, uw_Basis_client cli, void *data) {
void uw_post_expunge(uw_context ctx, void *data) {
}
+
+int uw_supports_direct_status = 1;
diff --git a/src/c/fastcgi.c b/src/c/fastcgi.c
index 4e20cc01..756ed3b0 100644
--- a/src/c/fastcgi.c
+++ b/src/c/fastcgi.c
@@ -618,3 +618,5 @@ void uw_do_expunge(uw_context ctx, uw_Basis_client cli, void *data) {
void uw_post_expunge(uw_context ctx, void *data) {
}
+
+int uw_supports_direct_status = 0;
diff --git a/src/c/http.c b/src/c/http.c
index 5754d229..d52661ce 100644
--- a/src/c/http.c
+++ b/src/c/http.c
@@ -358,3 +358,5 @@ void uw_do_expunge(uw_context ctx, uw_Basis_client cli, void *data) {
void uw_post_expunge(uw_context ctx, void *data) {
}
+
+int uw_supports_direct_status = 1;
diff --git a/src/c/request.c b/src/c/request.c
index 190a327f..52006e85 100644
--- a/src/c/request.c
+++ b/src/c/request.c
@@ -211,7 +211,7 @@ request_result uw_request(uw_request_context rc, uw_context ctx,
if (id && pass) {
unsigned idn = atoi(id);
uw_client_connect(idn, atoi(pass), sock, send, close, logger_data, log_error);
- log_error(logger_data, "Processed request for messages by client %u\n\n", idn);
+ log_debug(logger_data, "Processed request for messages by client %u\n\n", idn);
return KEEP_OPEN;
}
else {
diff --git a/src/cjr_print.sml b/src/cjr_print.sml
index 29f94fe6..e440a53d 100644
--- a/src/cjr_print.sml
+++ b/src/cjr_print.sml
@@ -2924,7 +2924,7 @@ fun p_file env (ds, ps) =
newline,
box [string "uw_clear_headers(ctx);",
newline,
- string "uw_write_header(ctx, \"HTTP/1.1 304 Not Modified\\r\\n\");",
+ string "uw_write_header(ctx, uw_supports_direct_status ? \"HTTP/1.1 304 Not Modified\\r\\n\" : \"Status: 304 Not Modified\\r\\n\");",
newline,
string "return;",
newline],