You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that all the created keys have the same value in them, only the unix timestamp is different. It is due to this line of code. Unless you generate too many keys too fast, differentiating by the unix timestamp is enough, therefore this is more of a cosmetic problem but the random value there seems redundant at this point.
Adding for example std::srand(clock()) before calling rand() fixes the problem. I am not a C++ programmer therefore I don't know where best to add it. I put mine at the start of the main function which made the value after unix timestamp actually random.
The text was updated successfully, but these errors were encountered:
I noticed that all the created keys have the same value in them, only the unix timestamp is different. It is due to this line of code. Unless you generate too many keys too fast, differentiating by the unix timestamp is enough, therefore this is more of a cosmetic problem but the random value there seems redundant at this point.
Adding for example
std::srand(clock())
before callingrand()
fixes the problem. I am not a C++ programmer therefore I don't know where best to add it. I put mine at the start of the main function which made the value after unix timestamp actually random.The text was updated successfully, but these errors were encountered: