diff http.c @ 74:67b3d13a5035

pasterd: make own HTML code for good
author David Demelier <markand@malikania.fr>
date Wed, 15 Mar 2023 19:34:00 +0100
parents 1a98bc0daa49
children 52029a52a385
line wrap: on
line diff
--- a/http.c	Tue Feb 21 22:22:02 2023 +0100
+++ b/http.c	Wed Mar 15 19:34:00 2023 +0100
@@ -75,7 +75,7 @@
 	log_debug("http: accessing page '%s'", req->path);
 
 	if (req->page == PAGE_LAST)
-		page(req, NULL, KHTTP_404, "pages/404.html", "404");
+		page_status(req, KHTTP_404);
 	else
 		handlers[req->page](req);
 }
@@ -94,12 +94,3 @@
 
 	khttp_fcgi_free(fcgi);
 }
-
-void
-http_cgi_run(void)
-{
-	struct kreq req;
-
-	if (khttp_parse(&req, NULL, 0, pages, PAGE_LAST, 0) == KCGI_OK)
-		process(&req);
-}