summaryrefslogtreecommitdiff
path: root/src/helperfuncs.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-07-19 11:13:15 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-07-19 11:13:15 +0000
commite8c920ce01a47e7b05ca3d445c3d8d88f9c70e37 (patch)
tree71b7f229411012db37a1d3b740d5eb426809be80 /src/helperfuncs.cpp
parentb137f2564c6a9d785c468d1facd54471a51db087 (diff)
Change size of already_sent from char to int to work with uniq_id value
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4438 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/helperfuncs.cpp')
-rw-r--r--src/helperfuncs.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/helperfuncs.cpp b/src/helperfuncs.cpp
index ea7f558db..9598c31a0 100644
--- a/src/helperfuncs.cpp
+++ b/src/helperfuncs.cpp
@@ -51,7 +51,7 @@ extern InspIRCd* ServerInstance;
extern time_t TIME;
extern char lowermap[255];
extern userrec* fd_ref_table[MAX_DESCRIPTORS];
-static char already_sent[MAX_DESCRIPTORS];
+static int already_sent[MAX_DESCRIPTORS];
extern std::vector<userrec*> all_opers;
extern user_hash clientlist;
extern chan_hash chanlist;
@@ -1235,13 +1235,14 @@ void purge_empty_chans(userrec* u)
// firstly decrement the count on each channel
for (std::vector<ucrec*>::iterator f = u->chans.begin(); f != u->chans.end(); f++)
{
- if (((ucrec*)(*f))->channel)
+ ucrec* uc = (ucrec*)(*f);
+ if (uc->channel)
{
- if (((ucrec*)(*f))->channel->DelUser(u) == 0)
+ if (uc->channel->DelUser(u) == 0)
{
/* No users left in here, mark it for deletion */
- to_delete.push_back(((ucrec*)(*f))->channel);
- ((ucrec*)(*f))->channel = NULL;
+ to_delete.push_back(uc->channel);
+ uc->channel = NULL;
}
}
}