aboutsummaryrefslogtreecommitdiffstats
path: root/lib/inets/src/http_server
diff options
context:
space:
mode:
authorErlang/OTP <[email protected]>2018-08-14 18:33:05 +0200
committerErlang/OTP <[email protected]>2018-08-14 18:33:05 +0200
commita6594645077ef47207844610134a6b23f4ed2bdb (patch)
tree4ebbb39ed046988b14d499a370a979b9ab397404 /lib/inets/src/http_server
parentfe34bce692c8f83f46771f1f85a62137de10edd7 (diff)
parenta164acd59ec2c99ab6fe32529ae1369252b004fa (diff)
downloadotp-a6594645077ef47207844610134a6b23f4ed2bdb.tar.gz
otp-a6594645077ef47207844610134a6b23f4ed2bdb.tar.bz2
otp-a6594645077ef47207844610134a6b23f4ed2bdb.zip
Merge branch 'ingela/inets/maint-20/status-501/ERIERL-218/OTP-15215' into maint-20
* ingela/inets/maint-20/status-501/ERIERL-218/OTP-15215: inets: Prepare for release inets: Use status code 501 when no mod_* handles the request # Conflicts: # lib/inets/test/httpd_SUITE.erl # lib/inets/vsn.mk
Diffstat (limited to 'lib/inets/src/http_server')
-rw-r--r--lib/inets/src/http_server/httpd_response.erl8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/inets/src/http_server/httpd_response.erl b/lib/inets/src/http_server/httpd_response.erl
index 6b9053fda6..0bcdee1e16 100644
--- a/lib/inets/src/http_server/httpd_response.erl
+++ b/lib/inets/src/http_server/httpd_response.erl
@@ -61,8 +61,12 @@ generate_and_send_response(#mod{config_db = ConfigDB} = ModData) ->
{StatusCode, Response} -> %% Old way
send_response_old(ModData, StatusCode, Response),
ok;
- undefined ->
- send_status(ModData, 500, none),
+ undefined ->
+ %% Happens when no mod_*
+ %% handles the request
+ send_status(ModData, 501, {ModData#mod.method,
+ ModData#mod.request_uri,
+ ModData#mod.http_version}),
ok
end
end