Increase entropy in test temp directory name

This commit is contained in:
Pieter Wuille 2018-04-09 15:24:25 -07:00 committed by Cory Fields
parent f6dfb0f504
commit 7ef9cd8491
1 changed files with 1 additions and 1 deletions

View File

@ -68,7 +68,7 @@ TestingSetup::TestingSetup(const std::string& chainName) : BasicTestingSetup(cha
RegisterAllCoreRPCCommands(tableRPC);
ClearDatadirCache();
pathTemp = fs::temp_directory_path() / strprintf("test_bitcoin_%lu_%i", (unsigned long)GetTime(), (int)(InsecureRandRange(100000)));
pathTemp = fs::temp_directory_path() / strprintf("test_bitcoin_%lu_%i", (unsigned long)GetTime(), (int)(InsecureRandRange(1 << 30)));
fs::create_directories(pathTemp);
gArgs.ForceSetArg("-datadir", pathTemp.string());