mirror of
https://git.suyu.dev/suyu/discord-rpc.git
synced 2026-01-01 12:15:46 +01:00
Seed random number generator
This commit is contained in:
parent
52bdc2714d
commit
059ab337c8
1 changed files with 2 additions and 0 deletions
|
|
@ -3,6 +3,7 @@
|
|||
#include <stdint.h>
|
||||
#include <algorithm>
|
||||
#include <random>
|
||||
#include <time.h>
|
||||
|
||||
struct Backoff {
|
||||
int64_t minAmount;
|
||||
|
|
@ -19,6 +20,7 @@ struct Backoff {
|
|||
, maxAmount(max)
|
||||
, current(min)
|
||||
, fails(0)
|
||||
, randGenerator(time(0))
|
||||
{
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue