aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorAndrey Pampukha <[email protected]>2010-05-11 17:54:13 +0200
committerRaimo Niskanen <[email protected]>2010-06-09 16:19:17 +0200
commit2a8a08a1752392a5e9e745c2a0929642812333e0 (patch)
treeace3c041d974d495c2f33702561267d007648616 /lib
parentdbecad9f8004f0a9b53ebdeb1ce8bde35dca7663 (diff)
downloadotp-2a8a08a1752392a5e9e745c2a0929642812333e0.tar.gz
otp-2a8a08a1752392a5e9e745c2a0929642812333e0.tar.bz2
otp-2a8a08a1752392a5e9e745c2a0929642812333e0.zip
Modify cookie handling in ct_slave
Diffstat (limited to 'lib')
-rw-r--r--lib/common_test/src/ct_slave.erl8
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/common_test/src/ct_slave.erl b/lib/common_test/src/ct_slave.erl
index 57170220b8..bf7ee8863c 100644
--- a/lib/common_test/src/ct_slave.erl
+++ b/lib/common_test/src/ct_slave.erl
@@ -321,9 +321,9 @@ do_start(Host, Node, Options)->
long_or_short()->
case net_kernel:longnames() of
true->
- "-name";
+ " -name ";
false->
- "-sname"
+ " -sname "
end.
% get the localhost's name, depending on the using name policy
@@ -339,7 +339,9 @@ gethostname()->
% get cmd for starting Erlang
get_cmd(Node)->
- "erl -detached -noinput "++ long_or_short() ++ " " ++ atom_to_list(Node).
+ Cookie = erlang:get_cookie(),
+ "erl -detached -noinput -setcookie "++ atom_to_list(Cookie) ++
+ long_or_short() ++ atom_to_list(Node).
% spawn node locally
spawn_local_node(Node)->