From 7e651907c0d90b820205c76a4f4a3be5428976a2 Mon Sep 17 00:00:00 2001 From: Patrick Pelissier Date: Sat, 22 Jul 2017 19:24:10 +0200 Subject: [PATCH] Fix issue with the computation (orders of the call to rand_get) --- bench/bench-mlib.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bench/bench-mlib.c b/bench/bench-mlib.c index 8c3b9a0c..01f0bf59 100644 --- a/bench/bench-mlib.c +++ b/bench/bench-mlib.c @@ -116,7 +116,8 @@ test_dict(unsigned long n) #endif M_LET(dict, DICT_OPLIST(ulong)) { for (size_t i = 0; i < n; i++) { - dict_ulong_set_at(dict, rand_get(), rand_get() ); + unsigned long key = rand_get(); + dict_ulong_set_at(dict, key, rand_get() ); } rand_init(); unsigned int s = 0;