aboutsummaryrefslogtreecommitdiffstats
path: root/lib/test_server/src/test_server_node.erl
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2015-02-19 15:35:44 +0100
committerRickard Green <[email protected]>2015-03-20 15:28:53 +0100
commitd2c19c15b887d44b92fa36c5f49d7f2ff755f8ad (patch)
treeea16cd65612e10521b6b1402f0e6df591489b80a /lib/test_server/src/test_server_node.erl
parentd6c23051e42928099fdcad4199bc89503ca6f2d9 (diff)
downloadotp-d2c19c15b887d44b92fa36c5f49d7f2ff755f8ad.tar.gz
otp-d2c19c15b887d44b92fa36c5f49d7f2ff755f8ad.tar.bz2
otp-d2c19c15b887d44b92fa36c5f49d7f2ff755f8ad.zip
test_server: Replace usage of erlang:now() with usage of new API
Diffstat (limited to 'lib/test_server/src/test_server_node.erl')
-rw-r--r--lib/test_server/src/test_server_node.erl5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/test_server/src/test_server_node.erl b/lib/test_server/src/test_server_node.erl
index acd47788db..9d87eca07e 100644
--- a/lib/test_server/src/test_server_node.erl
+++ b/lib/test_server/src/test_server_node.erl
@@ -618,9 +618,8 @@ do_quote_progname([Prog,Arg|Args]) ->
end.
random_element(L) ->
- {A,B,C} = now(),
- E = lists:sum([A,B,C]) rem length(L),
- lists:nth(E+1, L).
+ random:seed(os:timestamp()),
+ lists:nth(random:uniform(length(L)), L).
find_release(latest) ->
"/usr/local/otp/releases/latest/bin/erl";