From b38c2c8f67772f8260bfaa99ea110212b3a3df57 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Tue, 6 May 2014 17:30:38 +0200 Subject: inets: Correct distirbing mode for httpd:reload_config/2 config_reload tests are not enough to test httpd "block/unblock" used by config_reload, so renable some test cases in the old_httpd_SUITE after making them work with the new code. Should be cleaned up and moved to httpd_SUITE. --- lib/inets/src/http_server/httpd.erl | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'lib/inets/src/http_server/httpd.erl') diff --git a/lib/inets/src/http_server/httpd.erl b/lib/inets/src/http_server/httpd.erl index 6052ae9022..e8148ea362 100644 --- a/lib/inets/src/http_server/httpd.erl +++ b/lib/inets/src/http_server/httpd.erl @@ -1,7 +1,7 @@ %% %% %CopyrightBegin% %% -%% Copyright Ericsson AB 1997-2013. 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 @@ -294,9 +294,13 @@ do_reload_config(ConfigList, Mode) -> {ok, Config} -> Address = proplists:get_value(bind_address, Config, any), Port = proplists:get_value(port, Config, 80), - block(Address, Port, Mode), - reload(Config, Address, Port), - unblock(Address, Port); + case block(Address, Port, Mode) of + ok -> + reload(Config, Address, Port), + unblock(Address, Port); + Error -> + Error + end; Error -> Error end. -- cgit v1.2.3