diff options
| author | 2019-07-29 20:35:52 +0000 | |
|---|---|---|
| committer | 2019-07-29 20:35:52 +0000 | |
| commit | 1a902d383eef1e042d4462cd07b9384fcdf4d118 (patch) | |
| tree | 766b8ab720fa5da11730d2fc2388f51b9d14de49 /die.cpp | |
| parent | f5906125576a8323a731c9456ce3dfc53b67ef59 (diff) | |
| parent | 0d4b68221bda594cc695d216dfa21306ddb69c85 (diff) | |
| download | OneRoll-1a902d383eef1e042d4462cd07b9384fcdf4d118.tar.gz OneRoll-1a902d383eef1e042d4462cd07b9384fcdf4d118.zip | |
Merge branch 'liberation' into 'master'
Add fuzzer on the DiceParser
See merge request kde/rolisteam-diceparser!2
Diffstat (limited to 'die.cpp')
| -rw-r--r-- | die.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -35,7 +35,7 @@ Die::Die() , m_op(Die::PLUS) //,m_mt(m_randomDevice) { auto seed= std::chrono::high_resolution_clock::now().time_since_epoch().count(); - m_rng= std::mt19937(quintptr(this) + seed); + m_rng= std::mt19937(quintptr(this) + static_cast<unsigned long long>(seed)); } Die::Die(const Die& die) { @@ -49,6 +49,8 @@ Die::Die(const Die& die) m_base= die.m_base; m_color= die.getColor(); m_op= die.getOp(); + auto seed= std::chrono::high_resolution_clock::now().time_since_epoch().count(); + m_rng= std::mt19937(quintptr(this) + static_cast<unsigned long long>(seed)); } void Die::setValue(qint64 r) |