diff --git a/src/ec_file.erl b/src/ec_file.erl index cc3d1c4..4d19958 100644 --- a/src/ec_file.erl +++ b/src/ec_file.erl @@ -223,7 +223,7 @@ real_dir_path(Path) -> %% function of the same name. -spec insecure_mkdtemp() -> TmpDirPath::file:name() | {error, term()}. insecure_mkdtemp() -> - UniqueNumber = erlang:integer_to_list(erlang:trunc(random_uniform() * 1000000000000)), + UniqueNumber = erlang:integer_to_list(erlang:trunc(rand:uniform() * 1_000_000_000_000)), TmpDirPath = filename:join([tmp(), lists:flatten([".tmp_dir", UniqueNumber])]), @@ -376,9 +376,6 @@ sub_files(From) -> {ok, SubFiles} = file:list_dir(From), [filename:join(From, SubFile) || SubFile <- SubFiles]. -random_uniform() -> - rand:uniform(). - %%%=================================================================== %%% Test Functions %%%===================================================================