anchor.diff:  	Tokens = cowboy_http:nonempty_list(ReplyConn, fun cowboy_http:token/2),
   	cowboy_http:connection_to_atom(Tokens).
   
  --spec response_head(cowboy_http:status(), cowboy_http:headers(),
  -	cowboy_http:headers(), cowboy_http:headers()) -> iolist().
  -response_head(Status, Headers, RespHeaders, DefaultHeaders) ->
  -	StatusLine = <<"HTTP/1.1 ", (status(Status))/binary, "\r\n">>,
  +-spec response_merge_headers(cowboy_http:headers(), cowboy_http:headers(),
  +	cowboy_http:headers()) -> cowboy_http:headers().
  +response_merge_headers(Headers, RespHeaders, DefaultHeaders) ->
   	Headers2 = [{header_to_binary(Key), Value} || {Key, Value} <- Headers],
  -	Headers3 = merge_headers(
  +	merge_headers(
   		merge_headers(Headers2, RespHeaders),
  -		DefaultHeaders),
  -	Headers4 = [[Key, <<": ">>, Value, <<"\r\n">>]
  -		|| {Key, Value} <- Headers3],
  -	[StatusLine, Headers4, <<"\r\n">>].
  +		DefaultHeaders).
   
   -spec merge_headers(cowboy_http:headers(), cowboy_http:headers())
   	-> cowboy_http:headers().
  
positive.code: %% @see cowboy_http_req:chunk/2
  -spec chunked_reply(cowboy_http:status(), cowboy_http:headers(), #http_req{})
  	-> {ok, #http_req{}}.
  chunked_reply(Status, Headers, Req=#http_req{socket=Socket,
  		transport=Transport, version=Version, connection=Connection,
  		pid=ReqPid, resp_state=waiting, resp_headers=RespHeaders}) ->
  	RespConn = response_connection(Headers, Connection),
  	DefaultHeaders = [
  		{<<"Date">>, cowboy_clock:rfc1123()},
  		{<<"Server">>, <<"Cowboy">>}
  	],
  	DefaultHeaders2 = case Version of
  		{1, 1} -> [
  				{<<"Connection">>, atom_to_connection(Connection)},
  				{<<"Transfer-Encoding">>, <<"chunked">>}
  			] ++ DefaultHeaders;
  		_ -> DefaultHeaders
  	end,
  	Head = response_head(Status, Headers, RespHeaders, DefaultHeaders2),
  	Transport:send(Socket, Head),
  	ReqPid ! {?MODULE, resp_sent},
  	{ok, Req#http_req{connection=RespConn, resp_state=chunks,
  		resp_headers=[], resp_body= <<>>}}.
  
negative.code: %% @private
  -spec upgrade_reply(cowboy_http:status(), cowboy_http:headers(), #http_req{})
  	-> {ok, #http_req{}}.
  upgrade_reply(Status, Headers, Req=#http_req{
  		pid=ReqPid, resp_state=waiting, resp_headers=RespHeaders}) ->
  	response(Status, Headers, RespHeaders, [
  		{<<"Connection">>, <<"Upgrade">>}
  	], Req),
  	ReqPid ! {?MODULE, resp_sent},
  	{ok, Req#http_req{resp_state=done, resp_headers=[], resp_body= <<>>}}.
  
  