[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160715210953.GC19522@mwanda>
Date: Sat, 16 Jul 2016 00:09:53 +0300
From: Dan Carpenter <dan.carpenter@...cle.com>
To: Matthew Wilcox <willy@...ux.intel.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Ross Zwisler <ross.zwisler@...ux.intel.com>,
Konstantin Khlebnikov <koct9i@...il.com>,
linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org
Subject: [patch] testing/radix-tree: fix a macro expansion bug
There are no parentheses around this macro and it causes a problem when
we do:
index = rand() % THRASH_SIZE;
Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
diff --git a/tools/testing/radix-tree/tag_check.c b/tools/testing/radix-tree/tag_check.c
index b7447ce..b0ac057 100644
--- a/tools/testing/radix-tree/tag_check.c
+++ b/tools/testing/radix-tree/tag_check.c
@@ -122,7 +122,7 @@ enum {
NODE_TAGGED = 2,
};
-#define THRASH_SIZE 1000 * 1000
+#define THRASH_SIZE (1000 * 1000)
#define N 127
#define BATCH 33
Powered by blists - more mailing lists