kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch] testing/radix-tree: fix a macro expansion bug
@ 2016-07-15 21:09 Dan Carpenter
  2016-07-15 21:42 ` Ross Zwisler
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2016-07-15 21:09 UTC (permalink / raw)
  To: Matthew Wilcox
  Cc: Andrew Morton, Ross Zwisler, Konstantin Khlebnikov, linux-kernel,
	kernel-janitors

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@oracle.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
 

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-07-15 21:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-15 21:09 [patch] testing/radix-tree: fix a macro expansion bug Dan Carpenter
2016-07-15 21:42 ` Ross Zwisler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).