From 9868276d3be84183a41628bc9eca52b284bb5a9b Mon Sep 17 00:00:00 2001 From: "Pedro F. Giffuni" Date: Mon, 8 Feb 2016 19:45:55 +0000 Subject: [PATCH] ficl: Replace rand(3) with random(3). While the later is a better random generator than the former, the main reason of the change is that random() has a better chance to work with libstand(3). At this time we don't include random number generators in bootforth so this has no effect. --- sys/boot/ficl/words.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/boot/ficl/words.c b/sys/boot/ficl/words.c index c32e352b7330..5537b13a5a96 100644 --- a/sys/boot/ficl/words.c +++ b/sys/boot/ficl/words.c @@ -4822,7 +4822,7 @@ WORDKIND ficlWordClassify(FICL_WORD *pFW) **************************************************************************/ static void ficlRandom(FICL_VM *pVM) { - PUSHINT(rand()); + PUSHINT(random()); } @@ -4832,7 +4832,7 @@ static void ficlRandom(FICL_VM *pVM) **************************************************************************/ static void ficlSeedRandom(FICL_VM *pVM) { - srand(POPINT()); + srandom(POPUNS()); } #endif