Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lib/{mnesia,stdlib}: replace random functions by rand functions #9210

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions lib/mnesia/examples/bench/bench_populate.erl
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,8 @@ populate_subscriber(Wlock, C) ->
do_populate_subscriber(Wlock, Id, C) when Id >= 0 ->
Suffix = bench_trans:number_to_suffix(Id),
SubscrId = bench_trans:number_to_key(Id, C),
Name = list_to_binary([random:uniform(26) + $A - 1]),
GroupId = random:uniform(C#config.n_groups) - 1,
Name = list_to_binary([rand:uniform(26) + $A - 1]),
GroupId = rand:uniform(C#config.n_groups) - 1,
Subscr = #subscriber{subscriber_number = SubscrId,
subscriber_name = Name,
group_id = GroupId,
Expand Down Expand Up @@ -158,7 +158,7 @@ init_allow(C) ->
do_init_allow(0, C#config.n_servers - 1).

do_init_allow(Allow, NS) when NS >= 0 ->
case random:uniform(100) < (90 + 1) of
case rand:uniform(100) < (90 + 1) of
true ->
ServerBit = 1 bsl NS,
do_init_allow(Allow bor ServerBit, NS - 1);
Expand Down
Loading