From 173bc63cb59bbf19e73d1b823e3e9423c9f79860 Mon Sep 17 00:00:00 2001 From: Attila Molnar Date: Mon, 14 Jul 2014 16:04:38 +0200 Subject: Change return type of Channel::GetUsers() to reference from pointer as it is never NULL --- src/modules/m_deaf.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/modules/m_deaf.cpp') diff --git a/src/modules/m_deaf.cpp b/src/modules/m_deaf.cpp index 9800b32a9..5c4f7b2b6 100644 --- a/src/modules/m_deaf.cpp +++ b/src/modules/m_deaf.cpp @@ -66,7 +66,6 @@ class ModuleDeaf : public Module return MOD_RES_PASSTHRU; Channel* chan = static_cast(dest); - const UserMembList *ulist = chan->GetUsers(); bool is_bypasschar = (deaf_bypasschars.find(text[0]) != std::string::npos); bool is_bypasschar_uline = (deaf_bypasschars_uline.find(text[0]) != std::string::npos); @@ -77,7 +76,8 @@ class ModuleDeaf : public Module if (!deaf_bypasschars_uline.empty() && is_bypasschar) return MOD_RES_PASSTHRU; - for (UserMembCIter i = ulist->begin(); i != ulist->end(); i++) + const UserMembList& ulist = chan->GetUsers(); + for (UserMembCIter i = ulist.begin(); i != ulist.end(); ++i) { /* not +d ? */ if (!i->first->IsModeSet(m1)) -- cgit v1.3.1-10-gc9f91