diff options
author | William Pitcock <nenolod@dereferenced.org> | 2012-05-15 01:26:39 -0500 |
---|---|---|
committer | William Pitcock <nenolod@dereferenced.org> | 2012-05-15 01:26:39 -0500 |
commit | 663f0620bea4dc1e64ec640992f4d511ae1ef97b (patch) | |
tree | 5d8b007d4309f6a3820b5bb274d41f41c6625249 | |
parent | bf3bf3c9509de1cd85f1a8c375f995087c4c8cfd (diff) |
mlock: handle case where no mlock has been set on a channel yet
-rw-r--r-- | src/modules/m_mlock.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
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++) |