aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorIngela Anderton Andin <[email protected]>2014-04-01 08:49:18 +0200
committerIngela Anderton Andin <[email protected]>2014-04-01 08:49:18 +0200
commit3ccf4a77ee8ff4ca86ec2c46c2645607c094e800 (patch)
tree339f64472a50b50a830730f9321d101fc36d8d66 /lib
parent9894c51f3be4362a4d5edc05bf7e977a5e16bd26 (diff)
parent704481c61c1e0e17d0ffed8cbff4bf746a2147eb (diff)
downloadotp-3ccf4a77ee8ff4ca86ec2c46c2645607c094e800.tar.gz
otp-3ccf4a77ee8ff4ca86ec2c46c2645607c094e800.tar.bz2
otp-3ccf4a77ee8ff4ca86ec2c46c2645607c094e800.zip
Merge branch 'ia/inets/dialyzer'
* ia/inets/dialyzer: inets: Handle all response codes in httpd_util:message/3
Diffstat (limited to 'lib')
-rw-r--r--lib/inets/src/http_server/httpd_util.erl9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/inets/src/http_server/httpd_util.erl b/lib/inets/src/http_server/httpd_util.erl
index b0b18b9c3d..0d04a75205 100644
--- a/lib/inets/src/http_server/httpd_util.erl
+++ b/lib/inets/src/http_server/httpd_util.erl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 1997-2011. All Rights Reserved.
+%% Copyright Ericsson AB 1997-2014. All Rights Reserved.
%%
%% The contents of this file are subject to the Erlang Public License,
%% Version 1.1, (the "License"); you may not use this file except in
@@ -206,9 +206,6 @@ message(413, Reason,_) ->
"Entity: " ++ html_encode(Reason);
message(414,ReasonPhrase,_) ->
"Message " ++ html_encode(ReasonPhrase) ++ ".";
-message(416,ReasonPhrase,_) ->
- html_encode(ReasonPhrase);
-
message(500,_,ConfigDB) ->
ServerAdmin=lookup(ConfigDB,server_admin,"unknown@unknown"),
"The server encountered an internal error or "
@@ -233,7 +230,9 @@ message(501,{Method, RequestURI, HTTPVersion}, _ConfigDB) ->
end;
message(503, String, _ConfigDB) ->
- "This service in unavailable due to: " ++ html_encode(String).
+ "This service in unavailable due to: " ++ html_encode(String);
+message(_, ReasonPhrase, _) ->
+ html_encode(ReasonPhrase).
maybe_encode(URI) ->
Decoded = try http_uri:decode(URI) of