aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngela Anderton Andin <[email protected]>2014-03-21 15:30:29 +0100
committerIngela Anderton Andin <[email protected]>2014-03-21 15:30:29 +0100
commit5fe297b3193eee2c0c2544b3732bfa8a581ca99b (patch)
tree618a1bccfd4476e6ca5571bb59deb995c5ba1f99
parentbbe92ec2c359373205149dabc61ef0d50784760f (diff)
downloadotp-5fe297b3193eee2c0c2544b3732bfa8a581ca99b.tar.gz
otp-5fe297b3193eee2c0c2544b3732bfa8a581ca99b.tar.bz2
otp-5fe297b3193eee2c0c2544b3732bfa8a581ca99b.zip
inets: Remove potential windows problem
-rw-r--r--lib/inets/test/inets_sup_SUITE.erl15
1 files changed, 4 insertions, 11 deletions
diff --git a/lib/inets/test/inets_sup_SUITE.erl b/lib/inets/test/inets_sup_SUITE.erl
index 12b85a816f..cf28f5a245 100644
--- a/lib/inets/test/inets_sup_SUITE.erl
+++ b/lib/inets/test/inets_sup_SUITE.erl
@@ -260,10 +260,10 @@ tftpd_worker(suite) ->
[];
tftpd_worker(Config) when is_list(Config) ->
[] = supervisor:which_children(tftp_sup),
- {ok, Pid0} = inets:start(tftpd, [{host, "localhost"},
- {port, inet_port()}]),
- {ok, _Pid1} = inets:start(tftpd, [{host, "localhost"},
- {port, inet_port()}], stand_alone),
+ {ok, Pid0} = inets:start(tftpd, [{host, inets_test_lib:hostname()},
+ {port, 0}]),
+ {ok, _Pid1} = inets:start(tftpd, [{host, inets_test_lib:hostname()},
+ {port, 0}], stand_alone),
[{_,Pid0, worker, _}] = supervisor:which_children(tftp_sup),
inets:stop(tftpd, Pid0),
@@ -397,13 +397,6 @@ httpc_subtree(Config) when is_list(Config) ->
tsp("httpc_subtree -> done"),
ok.
-inet_port() ->
- {ok, Socket} = gen_tcp:listen(0, [{reuseaddr, true}]),
- {ok, Port} = inet:port(Socket),
- gen_tcp:close(Socket),
- Port.
-
-
tsp(F) ->
tsp(F, []).
tsp(F, A) ->