From dadc8fa40cc8054992ea2abbad244be25b89598c Mon Sep 17 00:00:00 2001 From: Bill Somerville Date: Thu, 18 May 2017 21:14:33 +0000 Subject: [PATCH] More entropy for RNG in simple WSPR Tx scheduler Better to come. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@7691 ab8295b8-cf94-4d9e-aec4-7959e3be5d79 --- WSPRBandHopping.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/WSPRBandHopping.cpp b/WSPRBandHopping.cpp index 61469ea52..978faa80b 100644 --- a/WSPRBandHopping.cpp +++ b/WSPRBandHopping.cpp @@ -214,7 +214,8 @@ public: , parent_widget_ {parent_widget} , last_was_tx_ {false} , carry_ {false} - , gen_ {rd_ ()} + , seed_ {{rand (), rand (), rand (), rand (), rand (), rand (), rand (), rand ()}} + , gen_ {seed_} , dist_ {1, 100} { auto num_bands = configuration_->bands ()->rowCount (); @@ -242,7 +243,7 @@ public: QPointer dialog_; bool last_was_tx_; bool carry_; - std::random_device rd_; + std::seed_seq seed_; std::mt19937 gen_; std::uniform_int_distribution dist_; };