X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fcoremods%2Fcore_who.cpp;h=39ea347dc8292b5c2b92f7cd908ddaa9c88e7acf;hb=47dda4f61512f6047f2b1dcccd1943aab74726e3;hp=d39c07520d93e07e02c592e878a6562507c1c0bf;hpb=173bc63cb59bbf19e73d1b823e3e9423c9f79860;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/coremods/core_who.cpp b/src/coremods/core_who.cpp index d39c07520..39ea347dc 100644 --- a/src/coremods/core_who.cpp +++ b/src/coremods/core_who.cpp @@ -42,7 +42,7 @@ class CommandWho : public Command Membership* get_first_visible_channel(User* u) { - for (UCListIter i = u->chans.begin(); i != u->chans.end(); ++i) + for (User::ChanList::iterator i = u->chans.begin(); i != u->chans.end(); ++i) { Membership* memb = *i; if (!memb->chan->IsModeSet(secretmode)) @@ -171,9 +171,6 @@ bool CommandWho::whomatch(User* cuser, User* user, const char* matchtext) bool CommandWho::CanView(Channel* chan, User* user) { - if (!user || !chan) - return false; - /* Bug #383 - moved higher up the list, because if we are in the channel * we can see all its users */ @@ -325,8 +322,8 @@ CmdResult CommandWho::Handle (const std::vector& parameters, User * bool inside = ch->HasUser(user); /* who on a channel. */ - const UserMembList& cu = ch->GetUsers(); - for (UserMembCIter i = cu.begin(); i != cu.end(); ++i) + const Channel::MemberMap& cu = ch->GetUsers(); + for (Channel::MemberMap::const_iterator i = cu.begin(); i != cu.end(); ++i) { /* None of this applies if we WHO ourselves */ if (user != i->first)