summaryrefslogtreecommitdiff
path: root/src/commands.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-04-13 12:41:46 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-04-13 12:41:46 +0000
commitc0f731e19d61a971af5cf26d073ccd25bfc5c91c (patch)
treecb070a261330b5110d30ecbcf4e446e1419886e2 /src/commands.cpp
parent58f076212f6330429e027576eb32cfc75bde82ae (diff)
Added Server::AddGLine
Added Server::AddKLine Added Server::AddZLine Added Server::AddQLine Added Server::AddELine Added Server::DelGLine Added Server::DelKLine Added Server::DelZLine Added Server::DelQLine Added Server::DelELine Added Server::Duration git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@1071 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/commands.cpp')
-rw-r--r--src/commands.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/commands.cpp b/src/commands.cpp
index bd2c57983..94635e609 100644
--- a/src/commands.cpp
+++ b/src/commands.cpp
@@ -2362,7 +2362,7 @@ void handle_hash(char token,char* params,serverrec* source,serverrec* reply, cha
char* create_time = strtok(NULL," ");
char* duration = strtok(NULL," :");
char* reason = strtok(NULL,"\r\n");
- add_gline(atoi(duration),who,reason,mask);
+ add_gline(atoi(duration),(const char*)who,(const char*)reason,(const char*)mask);
// we must update the creation time on this gline
// now that we've added it, or it wont expire at the right time.
gline_set_creation_time(mask,atoi(create_time));
@@ -2384,7 +2384,7 @@ void handle_dot(char token,char* params,serverrec* source,serverrec* reply, char
char* who = strtok(NULL," ");
if (mask)
{
- if (del_gline(mask))
+ if (del_gline((const char*)mask))
{
if (who)
{
@@ -2403,7 +2403,7 @@ void handle_add_sqline(char token,char* params,serverrec* source,serverrec* repl
char* create_time = strtok(NULL," ");
char* duration = strtok(NULL," :");
char* reason = strtok(NULL,"\r\n");
- add_qline(atoi(duration),who,reason,mask);
+ add_qline(atoi(duration),(const char*)who,(const char*)reason,(const char*)mask);
// we must update the creation time on this gline
// now that we've added it, or it wont expire at the right time.
qline_set_creation_time(mask,atoi(create_time));
@@ -2426,7 +2426,7 @@ void handle_del_sqline(char token,char* params,serverrec* source,serverrec* repl
char* who = strtok(NULL," ");
if (mask)
{
- if (del_qline(mask))
+ if (del_qline((const char*)mask))
{
if (who)
{
@@ -2445,7 +2445,7 @@ void handle_add_szline(char token,char* params,serverrec* source,serverrec* repl
char* create_time = strtok(NULL," ");
char* duration = strtok(NULL," :");
char* reason = strtok(NULL,"\r\n");
- add_zline(atoi(duration),who,reason,mask);
+ add_zline(atoi(duration),(const char*)who,(const char*)reason,(const char*)mask);
// we must update the creation time on this gline
// now that we've added it, or it wont expire at the right time.
zline_set_creation_time(mask,atoi(create_time));
@@ -2468,7 +2468,7 @@ void handle_del_szline(char token,char* params,serverrec* source,serverrec* repl
char* who = strtok(NULL," ");
if (mask)
{
- if (del_zline(mask))
+ if (del_zline((const char*)mask))
{
if (who)
{
@@ -3150,14 +3150,14 @@ void handle_link_packet(char* udp_msg, char* tcp_host, serverrec *serv)
}
}
-long duration(char* str)
+long duration(const char* str)
{
char n_field[MAXBUF];
long total = 0;
- char* str_end = str + strlen(str);
+ const char* str_end = str + strlen(str);
n_field[0] = 0;
- for (char* i = str; i < str_end; i++)
+ for (char* i = (char*)str; i < str_end; i++)
{
// if we have digits, build up a string for the value in n_field,
// up to 10 digits in size.