summaryrefslogtreecommitdiff
path: root/src/helperfuncs.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-12-16 01:20:04 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-12-16 01:20:04 +0000
commit3b3422271d77c199118296495dc0dbd86708fdfe (patch)
tree1a4bb113b1b8ba1fdcfcf5b7680fa6546b42bca4 /src/helperfuncs.cpp
parent0b6295a0aa384ba11522abf7b417593fb28c407c (diff)
Some things just cant be static...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2501 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/helperfuncs.cpp')
-rw-r--r--src/helperfuncs.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/helperfuncs.cpp b/src/helperfuncs.cpp
index 3f7e89d57..691d58509 100644
--- a/src/helperfuncs.cpp
+++ b/src/helperfuncs.cpp
@@ -64,16 +64,14 @@ extern chan_hash chanlist;
extern command_table cmdlist;
extern Module* IOHookModule;
-static char textbuffer[MAXBUF];
-static char tb[MAXBUF];
-
void log(int level,char *text, ...)
{
va_list argsPtr;
struct tm * timeinfo;
if (level < Config->LogLevel)
return;
-
+ char textbuffer[MAXBUF];
+ char tb[MAXBUF];
timeinfo = localtime(&TIME);
if (Config->log_file)
@@ -136,7 +134,7 @@ void Write(int sock,char *text, ...)
return;
}
va_list argsPtr;
-
+ char textbuffer[MAXBUF],tb[MAXBUF];
va_start (argsPtr, text);
vsnprintf(textbuffer, MAXBUF, text, argsPtr);
va_end(argsPtr);
@@ -170,7 +168,7 @@ void WriteServ(int sock, char* text, ...)
}
va_list argsPtr;
va_start (argsPtr, text);
-
+ char textbuffer[MAXBUF],tb[MAXBUF];
vsnprintf(textbuffer, MAXBUF, text, argsPtr);
va_end(argsPtr);
int bytes = snprintf(tb,MAXBUF,":%s %s\r\n",Config->ServerName,textbuffer);
@@ -203,7 +201,7 @@ void WriteFrom(int sock, userrec *user,char* text, ...)
}
va_list argsPtr;
va_start (argsPtr, text);
-
+ char textbuffer[MAXBUF],tb[MAXBUF];
vsnprintf(textbuffer, MAXBUF, text, argsPtr);
va_end(argsPtr);
int bytes = snprintf(tb,MAXBUF,":%s!%s@%s %s\r\n",user->nick,user->ident,user->dhost,textbuffer);
@@ -234,6 +232,7 @@ void WriteTo(userrec *source, userrec *dest,char *data, ...)
}
if (dest->fd == FD_MAGIC_NUMBER)
return;
+ char textbuffer[MAXBUF],tb[MAXBUF];
va_list argsPtr;
va_start (argsPtr, data);
vsnprintf(textbuffer, MAXBUF, data, argsPtr);