summaryrefslogtreecommitdiffstats
path: root/cli-miner.cpp
diff options
context:
space:
mode:
authorSChernykh <sergey.v.chernykh@gmail.com>2017-07-17 21:10:37 +0200
committerGitHub <noreply@github.com>2017-07-17 21:10:37 +0200
commitf5c2757b04c54636e442b62d9fd8b02999da03a8 (patch)
tree6898f95cad7f505d617312eeea0a6cfe5ae06754 /cli-miner.cpp
parent7ea46b04d811c8ca3fc7090f38357fc51b1d3b1b (diff)
downloadxmr-stak-f5c2757b04c54636e442b62d9fd8b02999da03a8.zip
xmr-stak-f5c2757b04c54636e442b62d9fd8b02999da03a8.tar.gz
Initialize random number generator
Diffstat (limited to 'cli-miner.cpp')
-rw-r--r--cli-miner.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/cli-miner.cpp b/cli-miner.cpp
index 43329e2..2dc5173 100644
--- a/cli-miner.cpp
+++ b/cli-miner.cpp
@@ -41,6 +41,8 @@
#include <stdio.h>
#include <string.h>
+#include <ctime>
+
#ifndef CONF_NO_TLS
#include <openssl/ssl.h>
#include <openssl/err.h>
@@ -74,6 +76,8 @@ int main(int argc, char *argv[])
OpenSSL_add_all_digests();
#endif
+ std::srand(std::time(0));
+
const char* sFilename = "config.txt";
bool benchmark_mode = false;
OpenPOWER on IntegriCloud