|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r51410 - trunk/boost/random
From: steven_at_[hidden]
Date: 2009-02-22 20:19:38
Author: steven_watanabe
Date: 2009-02-22 20:19:37 EST (Sun, 22 Feb 2009)
New Revision: 51410
URL: http://svn.boost.org/trac/boost/changeset/51410
Log:
Initialize _modulus in the linear_congruential constructor that takes a pair of iterators. Fixes #2665
Text files modified:
trunk/boost/random/linear_congruential.hpp | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
Modified: trunk/boost/random/linear_congruential.hpp
==============================================================================
--- trunk/boost/random/linear_congruential.hpp (original)
+++ trunk/boost/random/linear_congruential.hpp 2009-02-22 20:19:37 EST (Sun, 22 Feb 2009)
@@ -65,7 +65,11 @@
}
template<class It>
- linear_congruential(It& first, It last) { seed(first, last); }
+ linear_congruential(It& first, It last)
+ : _modulus(modulus)
+ {
+ seed(first, last);
+ }
// compiler-generated copy constructor and assignment operator are fine
void seed(IntType x0 = 1)
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk