summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Changes1
-rw-r--r--src/protocol/inspircd12.c15
-rw-r--r--src/protocol/inspircd20.c14
-rw-r--r--version.log5
4 files changed, 28 insertions, 7 deletions
diff --git a/Changes b/Changes
index 5e5cd5a53..d9048d9cd 100644
--- a/Changes
+++ b/Changes
@@ -1,5 +1,6 @@
Anope Version 1.8 - GIT
-----------------------
+05/30 F Fixed removing vhosts on InspIRCd when m_cloaking is unloaded [#1273]
Anope Version 1.8.6
diff --git a/src/protocol/inspircd12.c b/src/protocol/inspircd12.c
index e53ac735e..01703baed 100644
--- a/src/protocol/inspircd12.c
+++ b/src/protocol/inspircd12.c
@@ -426,6 +426,7 @@ static int has_blockcaps = 0;
static int has_nickflood = 0;
static int has_chanfilter = 0;
static int has_kicknorejoin = 0;
+static int has_cloaking = 0;
void inspircd_set_umode(User *user, int ac, char **av)
{
@@ -575,8 +576,15 @@ void inspircd_cmd_topic(char *whosets, char *chan, char *whosetit,
void inspircd_cmd_vhost_off(User * u)
{
- common_svsmode(u, "-x", NULL);
- common_svsmode(u, "+x", NULL);
+ if (has_cloaking)
+ {
+ common_svsmode(u, "-x", NULL);
+ common_svsmode(u, "+x", NULL);
+ }
+ else
+ {
+ inspircd_cmd_chghost(u->nick, u->host);
+ }
if (has_chgidentmod && u->username && u->vident && strcmp(u->username, u->vident) != 0)
{
@@ -1999,6 +2007,9 @@ int anope_event_capab(char *source, int ac, char **av)
if (strstr(av[1], "m_kicknorejoin.so")) {
has_kicknorejoin = 1;
}
+ if (strstr(av[1], "m_cloaking.so")) {
+ has_cloaking = 1;
+ }
} else if (strcasecmp(av[0], "END") == 0) {
if (!has_globopsmod) {
send_cmd(NULL, "ERROR :m_globops is not loaded. This is required by Anope");
diff --git a/src/protocol/inspircd20.c b/src/protocol/inspircd20.c
index d0239ef1c..969ad4a94 100644
--- a/src/protocol/inspircd20.c
+++ b/src/protocol/inspircd20.c
@@ -473,6 +473,7 @@ static int has_chghostmod = 0;
static int has_chgidentmod = 0;
static int has_servprotectmod = 0;
static int has_hidechansmod = 0;
+static int has_cloaking = 0;
void inspircd_set_umode(User *user, int ac, char **av)
{
@@ -622,8 +623,15 @@ void inspircd_cmd_topic(char *whosets, char *chan, char *whosetit,
void inspircd_cmd_vhost_off(User * u)
{
- common_svsmode(u, "-x", NULL);
- common_svsmode(u, "+x", NULL);
+ if (has_cloaking)
+ {
+ common_svsmode(u, "-x", NULL);
+ common_svsmode(u, "+x", NULL);
+ }
+ else
+ {
+ inspircd_cmd_chghost(u->nick, u->host);
+ }
if (has_chgidentmod && u->username && u->vident && strcmp(u->username, u->vident) != 0)
{
@@ -1915,6 +1923,8 @@ int anope_event_capab(char *source, int ac, char **av)
} else if (strcasecmp(av[0], "MODULES") == 0) {
if (strstr(av[1], "m_svshold.so"))
ircd->svshold = 1;
+ if (strstr(av[1], "m_cloaking.so"))
+ has_cloaking = 1;
} else if (strcasecmp(av[0], "CHANMODES") == 0) {
char **argv;
int argc = split_buf(av[1], &argv, 1);
diff --git a/version.log b/version.log
index 4257d58da..1e05c274a 100644
--- a/version.log
+++ b/version.log
@@ -8,11 +8,10 @@ VERSION_MAJOR="1"
VERSION_MINOR="8"
VERSION_PATCH="7"
VERSION_EXTRA="-git"
-VERSION_BUILD="3073"
+VERSION_BUILD="3074"
# $Log$ # Changes since 1.8.6 Release
-
-
+#Revision 3074 - Bug #1273 - Fixed removing vhosts on InspIRCd when m_cloaking is unloaded