diff options
author | Mikael Magnusson <mikma@users.sourceforge.net> | 2020-11-16 23:57:14 +0100 |
---|---|---|
committer | Mikael Magnusson <mikma@users.sourceforge.net> | 2020-11-16 23:57:14 +0100 |
commit | 064d391854f78ebb4fa311638dd0841227dc60b4 (patch) | |
tree | d925262fbc34ae68a5bcaa197d4fa4e4d587fb9f /src/html-error.c | |
parent | aeee18457c5834b06f902f25ca2e7b80302b9f97 (diff) | |
parent | 12403a9a19db8c3a31c92d57199e316e4d7a27a3 (diff) |
Merge branches 'bind-ipv4mapped' and 'support_http_11'
Diffstat (limited to 'src/html-error.c')
-rw-r--r-- | src/html-error.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/html-error.c b/src/html-error.c index 071d415..fcb0b94 100644 --- a/src/html-error.c +++ b/src/html-error.c @@ -136,7 +136,7 @@ send_html_file (FILE *infile, struct conn_s *connptr) int send_http_headers (struct conn_s *connptr, int code, const char *message) { const char headers[] = - "HTTP/1.0 %d %s\r\n" + "HTTP/1.%u %d %s\r\n" "Server: %s/%s\r\n" "Content-Type: text/html\r\n" "%s" @@ -155,6 +155,7 @@ int send_http_headers (struct conn_s *connptr, int code, const char *message) const char *add = code == 407 ? p_auth_str : (code == 401 ? w_auth_str : ""); return (write_message (connptr->client_fd, headers, + connptr->protocol.major != 1 ? 0 : connptr->protocol.minor, code, message, PACKAGE, VERSION, add)); } |