X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fchannels.cpp;h=0201ec7b4fc1f80a072598c980d01b0af8813dc0;hb=1f1258997c2d63eb54c5addece622af37f637a7b;hp=ef1f8b6ada537eb34c7340daa729e69709dd2231;hpb=0c7ed930d5b7975ab96764db200aaf383b7cde95;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/channels.cpp b/src/channels.cpp index ef1f8b6ad..0201ec7b4 100644 --- a/src/channels.cpp +++ b/src/channels.cpp @@ -19,7 +19,6 @@ using namespace std; #include "inspircd_config.h" #include "inspircd.h" #include "inspircd_io.h" -#include "inspircd_util.h" #include #include #include @@ -73,13 +72,8 @@ chanrec* ForceChan(chanrec* Ptr,ucrec &a,userrec* user, int created); chanrec::chanrec() { - strcpy(name,""); - strcpy(custom_modes,""); - strcpy(topic,""); - strcpy(setby,""); - strcpy(key,""); - created = topicset = limit = 0; - binarymodes = 0; + *name = *custom_modes = *topic = *setby = *key = 0; + created = topicset = limit = binarymodes = 0; internal_userlist.clear(); } @@ -223,7 +217,7 @@ chanrec* add_channel(userrec *user, const char* cn, const char* key, bool overri strlcpy(chanlist[cname]->name, cname,CHANMAX); chanlist[cname]->binarymodes = CM_TOPICLOCK | CM_NOEXTERNAL; chanlist[cname]->created = TIME; - strcpy(chanlist[cname]->topic, ""); + *chanlist[cname]->topic = 0; strncpy(chanlist[cname]->setby, user->nick,NICKMAX); chanlist[cname]->topicset = 0; Ptr = chanlist[cname];