summaryrefslogtreecommitdiffstats
path: root/usr.sbin/httpd
diff options
context:
space:
mode:
authorbentley <bentley@openbsd.org>2020-05-22 07:18:17 +0000
committerbentley <bentley@openbsd.org>2020-05-22 07:18:17 +0000
commit8643c0edbdaf122a89210ba0359ae06546ed9f17 (patch)
treec660feea8b343f688ad04b7cd1d22d0a375c4921 /usr.sbin/httpd
parentbetter wording (diff)
downloadwireguard-openbsd-8643c0edbdaf122a89210ba0359ae06546ed9f17.tar.xz
wireguard-openbsd-8643c0edbdaf122a89210ba0359ae06546ed9f17.zip
Use the simpler HTML5 idiom to declare charset in autogenerated pages.
This came from a suggestion by Andras Farkas to replace use of XHTML self-closing tags. ok cwen@ danj@ florian@
Diffstat (limited to 'usr.sbin/httpd')
-rw-r--r--usr.sbin/httpd/server_file.c5
-rw-r--r--usr.sbin/httpd/server_http.c5
2 files changed, 4 insertions, 6 deletions
diff --git a/usr.sbin/httpd/server_file.c b/usr.sbin/httpd/server_file.c
index e568b4503f2..d62590037ae 100644
--- a/usr.sbin/httpd/server_file.c
+++ b/usr.sbin/httpd/server_file.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: server_file.c,v 1.67 2020/05/18 14:40:06 cwen Exp $ */
+/* $OpenBSD: server_file.c,v 1.68 2020/05/22 07:18:17 bentley Exp $ */
/*
* Copyright (c) 2006 - 2017 Reyk Floeter <reyk@openbsd.org>
@@ -487,8 +487,7 @@ server_file_index(struct httpd *env, struct client *clt, struct stat *st)
"<!DOCTYPE html>\n"
"<html>\n"
"<head>\n"
- "<meta http-equiv=\"Content-Type\" content=\"text/html; "
- "charset=utf-8\"/>\n"
+ "<meta charset=\"utf-8\">\n"
"<title>Index of %s</title>\n"
"<style type=\"text/css\"><!--\n%s\n--></style>\n"
"</head>\n"
diff --git a/usr.sbin/httpd/server_http.c b/usr.sbin/httpd/server_http.c
index 3cbce9c5ff2..3bb5f64e221 100644
--- a/usr.sbin/httpd/server_http.c
+++ b/usr.sbin/httpd/server_http.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: server_http.c,v 1.138 2020/05/18 14:40:06 cwen Exp $ */
+/* $OpenBSD: server_http.c,v 1.139 2020/05/22 07:18:17 bentley Exp $ */
/*
* Copyright (c) 2006 - 2018 Reyk Floeter <reyk@openbsd.org>
@@ -931,8 +931,7 @@ server_abort_http(struct client *clt, unsigned int code, const char *msg)
"<!DOCTYPE html>\n"
"<html>\n"
"<head>\n"
- "<meta http-equiv=\"Content-Type\" content=\"text/html; "
- "charset=utf-8\"/>\n"
+ "<meta charset=\"utf-8\">\n"
"<title>%03d %s</title>\n"
"<style type=\"text/css\"><!--\n%s\n--></style>\n"
"</head>\n"