Browse Source

Make sure error_response always returns ok.

Loïc Hoguin 14 years ago
parent
commit
e9781e77f1
1 changed files with 2 additions and 1 deletions
  1. 2 1
      src/cowboy_http_protocol.erl

+ 2 - 1
src/cowboy_http_protocol.erl

@@ -196,7 +196,8 @@ error_response(Code, #state{socket=Socket,
 		transport=Transport, connection=Connection}) ->
 		transport=Transport, connection=Connection}) ->
 	cowboy_http_req:reply(Code, [], [], #http_req{
 	cowboy_http_req:reply(Code, [], [], #http_req{
 		socket=Socket, transport=Transport,
 		socket=Socket, transport=Transport,
-		connection=Connection, resp_state=waiting}).
+		connection=Connection, resp_state=waiting}),
+	ok.
 
 
 -spec error_terminate(Code::http_status(), State::#state{}) -> ok.
 -spec error_terminate(Code::http_status(), State::#state{}) -> ok.
 error_terminate(Code, State) ->
 error_terminate(Code, State) ->