Seed randomnes at Actor startup

This commit is contained in:
martinsumner 2017-03-06 21:35:02 +00:00
parent 32cdf26ffb
commit 9ad6969b0d
4 changed files with 9 additions and 5 deletions

View file

@ -222,6 +222,8 @@ ink_print_manifest(Pid) ->
%%%============================================================================
init([InkerOpts]) ->
SW = os:timestamp(),
random:seed(erlang:phash2(self()), element(2, SW), element(3, SW)),
case {InkerOpts#inker_options.root_path,
InkerOpts#inker_options.start_snapshot} of
{undefined, true} ->