When you need a web server in a hurry. http://unix4lyfe.org/darkhttpd/
Go to file
Emil Mikulic 2080b05d4c Starting work on Keep-Alive:
. Added conn_close to struct connection.
  0 = Keep-Alive, 1 = Connection: close
. Added keepalive_connection() for recycling connection structs.
. Made "Connection: close\r\n" in reply headers optional.
. If protocol is HTTP/1.1, use Keep-Alive, unless Connection: close is
  given in the request.

Offtopic:
. Improved request parsing - allow extraneous spaces.
2013-04-28 19:44:10 +10:00
trunk Starting work on Keep-Alive: 2013-04-28 19:44:10 +10:00