From 663f0620bea4dc1e64ec640992f4d511ae1ef97b Mon Sep 17 00:00:00 2001 From: William Pitcock Date: Tue, 15 May 2012 01:26:39 -0500 Subject: mlock: handle case where no mlock has been set on a channel yet --- src/modules/m_mlock.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/modules') diff --git a/src/modules/m_mlock.cpp b/src/modules/m_mlock.cpp index 7e891f146..45ad7453e 100644 --- a/src/modules/m_mlock.cpp +++ b/src/modules/m_mlock.cpp @@ -47,7 +47,7 @@ public: return MOD_RES_PASSTHRU; std::string *mlock_str = mlock.get(channel); - if (mlock_str->empty()) + if (!mlock_str || mlock_str->empty()) return MOD_RES_PASSTHRU; for (const char *modes = parameters[1].c_str(); *modes; modes++) -- cgit v1.2.3