summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/chanserv.c9
-rw-r--r--src/config.c2
-rw-r--r--src/modules.c2
3 files changed, 9 insertions, 4 deletions
diff --git a/src/chanserv.c b/src/chanserv.c
index 70643e7d6..f3bf88483 100644
--- a/src/chanserv.c
+++ b/src/chanserv.c
@@ -2210,20 +2210,23 @@ int get_access(User * user, ChannelInfo * ci)
ChanAccess *access;
if (!ci || !user)
- return 0;
+ return -1;
if (is_founder(user, ci))
return ACCESS_FOUNDER;
if (!user->na)
- return 0;
+ return -1;
if (nick_identified(user)
|| (nick_recognized(user) && !(ci->flags & CI_SECURE)))
if ((access = get_access_entry(user->na->nc, ci)))
return access->level;
- return 0;
+ if (nick_identified(user))
+ return 0;
+
+ return -1;
}
/*************************************************************************/
diff --git a/src/config.c b/src/config.c
index 7bf44b358..347f8cefe 100644
--- a/src/config.c
+++ b/src/config.c
@@ -858,7 +858,7 @@ int parse(char *buf, int linenum, int reload)
if (n == lenof(directives)) {
/* error(linenum, "Unknown directive `%s'", dir);
- return 1; *//* don't cause abort */
+ return 1; *//* don't cause abort */
}
return retval;
diff --git a/src/modules.c b/src/modules.c
index a32845f27..c721014b5 100644
--- a/src/modules.c
+++ b/src/modules.c
@@ -540,7 +540,9 @@ int unloadModule(Module * m, User * u)
func = ano_modsym(m->handle, "AnopeFini");
if (func) {
+ mod_current_module_name = m->name;
func(); /* exec AnopeFini */
+ mod_current_module_name = NULL;
}
if ((ano_modclose(m->handle)) != 0) {