Warning: Attempt to read property "date" on null in /usr/local/www/websvn.planix.org/blame.php on line 247

Warning: Attempt to read property "msg" on null in /usr/local/www/websvn.planix.org/blame.php on line 247
WebSVN – planix.SVN – Blame – /os/branches/feature_fixcpp/sys/src/libhttpd/okheaders.c – Rev 2

Subversion Repositories planix.SVN

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 - 1
#include <u.h>
2
#include <libc.h>
3
#include <bin.h>
4
#include <httpd.h>
5
 
6
/*
7
 * write initial part of successful header
8
 */
9
void
10
hokheaders(HConnect *c)
11
{
12
	Hio *hout;
13
 
14
	hout = &c->hout;
15
	hprint(hout, "%s 200 OK\r\n", hversion);
16
	hprint(hout, "Server: Plan9\r\n");
17
	hprint(hout, "Date: %D\r\n", time(nil));
18
	if(c->head.closeit)
19
		hprint(hout, "Connection: close\r\n");
20
	else if(!http11(c))
21
		hprint(hout, "Connection: Keep-Alive\r\n");
22
}