anchor.diff:  %% The Host header is required.
   header(http_eoh, #http_req{host=undefined}, State) ->
   	error_terminate(400, State);
  -header(http_eoh, Req=#http_req{host=Host, path=Path},
  -		State=#state{dispatch=Dispatch}) ->
  -	%% @todo We probably want to filter the Host and Patch here to allow
  -	%%       things like url rewriting.
  -	dispatch(cowboy_dispatcher:match(Host, Path, Dispatch), Req, State).
  -
  --spec dispatch({ok, Handler::module(), Opts::term(), Binds::bindings()}
  -	| {error, notfound}, Req::#http_req{}, State::#state{}) -> ok.
  -dispatch({ok, Handler, Opts, Binds}, Req, State) ->
  -	case Handler:handle(Opts, Req#http_req{bindings=Binds}) of
  +header(http_eoh, Req, State) ->
  +	handler_loop(Req, State).
  +
  +-spec handler_loop(Req::#http_req{}, State::#state{}) -> ok.
  +handler_loop(Req, State=#state{handler={Handler, Opts}}) ->
  +	case Handler:handle(Opts, Req) of
   		{reply, RCode, RHeaders, RBody} ->
   			reply(RCode, RHeaders, RBody, State)
   		%% @todo stream_reply, request_body, stream_request_body...
  -	end;
  -dispatch({error, notfound}, _Req, State) ->
  -	error_terminate(404, State).
  +	end.
   
   -spec error_terminate(Code::http_status(), State::#state{}) -> ok.
   error_terminate(Code, State) ->
  
positive.code: 
  -spec header({http_header, I::integer(), Field::http_header(), R::term(),
  	Value::string()} | http_eoh, Req::#http_req{}, State::#state{}) -> ok.
  header({http_header, _I, 'Host', _R, Value}, Req, State) ->
  	Host = cowboy_dispatcher:split_host(Value),
  	%% @todo We have Host and Path at this point, dispatch right away and
  	%%       error_terminate(404) early if it fails.
  	wait_header(Req#http_req{host=Host,
  		headers=[{'Host', Value}|Req#http_req.headers]}, State);
  header({http_header, _I, 'Connection', _R, Connection}, Req, State) ->
  	wait_header(Req#http_req{
  		headers=[{'Connection', Connection}|Req#http_req.headers]},
  
negative.code: 	socket :: socket(),
  	transport :: module(),
  	dispatch :: dispatch(),
  	handler :: {Handler::module(), Opts::term()},
  	timeout :: timeout(),
  	connection = keepalive :: keepalive | close
  }).
  