diff options
| author | Gavin Andresen <[email protected]> | 2011-12-20 08:52:22 -0800 |
|---|---|---|
| committer | Gavin Andresen <[email protected]> | 2011-12-20 08:52:22 -0800 |
| commit | 74f5435e104be76cd342a9a196ed4a10b8a7e248 (patch) | |
| tree | 254f76dfa15c36a359e661caa1b4cfd158e204f4 /src/util.cpp | |
| parent | Merge pull request #690 from runeksvendsen/qt-cmdline-options-parsing (diff) | |
| parent | Code cleanup: use ECDSA_size() instead of fixed 10,000 byte sig buffer, and e... (diff) | |
| download | discoin-74f5435e104be76cd342a9a196ed4a10b8a7e248.tar.xz discoin-74f5435e104be76cd342a9a196ed4a10b8a7e248.zip | |
Merge pull request #716 from gavinandresen/cleanup
Cleanups suggested by genjix
Diffstat (limited to 'src/util.cpp')
| -rw-r--r-- | src/util.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/util.cpp b/src/util.cpp index ef276e510..80ce40459 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -133,7 +133,7 @@ uint64 GetRand(uint64 nMax) // The range of the random source must be a multiple of the modulus // to give every possible output value an equal possibility - uint64 nRange = (UINT64_MAX / nMax) * nMax; + uint64 nRange = (std::numeric_limits<uint64>::max() / nMax) * nMax; uint64 nRand = 0; do RAND_bytes((unsigned char*)&nRand, sizeof(nRand)); |