summaryrefslogtreecommitdiff
path: root/test/suite/suite_random.py
diff options
context:
space:
mode:
authorKeith Bostic <keith@wiredtiger.com>2015-05-30 14:09:37 -0400
committerKeith Bostic <keith@wiredtiger.com>2015-05-30 14:09:37 -0400
commitbbd5c38c29d2601f935dd097afd3bd21be89a30c (patch)
tree60f8e157a54bbfb51a52d444cbfb698fbc73fc40 /test/suite/suite_random.py
parentd36c0922f2df75bc1ea8fb26f20a51c2f4173cf0 (diff)
downloadmongo-bbd5c38c29d2601f935dd097afd3bd21be89a30c.tar.gz
Revert the masking of the seeds, on second thought I think that's
correct.
Diffstat (limited to 'test/suite/suite_random.py')
-rw-r--r--test/suite/suite_random.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/suite/suite_random.py b/test/suite/suite_random.py
index 08cd3e89ab0..246afd9884d 100644
--- a/test/suite/suite_random.py
+++ b/test/suite/suite_random.py
@@ -38,11 +38,11 @@ class suite_random:
def __init__(self, *args):
arglen = len(args)
if arglen == 1:
- self.seedw = int(args[0])
- self.seedz = int(args[0])
+ self.seedw = int(args[0]) & 0xffffffff
+ self.seedz = int(args[0]) & 0xffffffff
elif arglen == 2:
- self.seedw = int(args[0])
- self.seedz = int(args[1])
+ self.seedw = int(args[0]) & 0xffffffff
+ self.seedz = int(args[1]) & 0xffffffff
else:
self.seedw = 521288629
self.seedz = 362436069
@@ -57,8 +57,8 @@ class suite_random:
self.seedw = 521288629
self.seedz = 362436069
- self.seedz = 36969 * (z & 65535) + (z >> 16)
- self.seedw = 18000 * (w & 65535) + (w >> 16)
+ self.seedz = (36969 * (z & 65535) + (z >> 16)) & 0xffffffff
+ self.seedw = (18000 * (w & 65535) + (w >> 16)) & 0xffffffff
return ((z << 16) + w & 65535) & 0xffffffff
def rand_range(self, n, m):