From 3ae5210daedc65958799d38dd9eb05a8b5beee6c Mon Sep 17 00:00:00 2001 From: frostycoolslug Date: Fri, 1 Apr 2005 19:08:21 +0000 Subject: Fixed the random seeder thingie! git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@939 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_randquote.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/modules/m_randquote.cpp b/src/modules/m_randquote.cpp index 01a6e3270..d3dfc5a45 100644 --- a/src/modules/m_randquote.cpp +++ b/src/modules/m_randquote.cpp @@ -39,7 +39,6 @@ void handle_randquote(char** parameters, int pcntl, userrec *user) char buf[MAXBUF]; fsize = quotes->FileSize(); - srand(time(NULL)); str = quotes->GetLine(rand() % fsize); sprintf(buf,"NOTICE %s :%s%s%s",user->nick,prefix.c_str(),str.c_str(),suffix.c_str()); @@ -60,6 +59,8 @@ class ModuleRandQuote : public Module { Srv = new Server; conf = new ConfigReader; + // Sort the Randomizer thingie.. + srand(time(NULL)); q_file = conf->ReadValue("randquote","file",0); -- cgit v1.2.3