summaryrefslogtreecommitdiff
path: root/modules/core
diff options
context:
space:
mode:
authormichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2014-02-25 20:42:44 +0000
committermichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2014-02-25 20:42:44 +0000
commit6e56a2b84df8b77b7119c4774d8d5fce708d71f9 (patch)
tree14840ee9cf7889782cfe305ef47104e4f970f0a4 /modules/core
parent61cb4365668096de035c23d9568f9ecbf831beab (diff)
- ms_bmask(), remove_ban_list(): removed capability tests for CAP_IE and CAP_EX
as +I and +e are mandatory for quite a while now git-svn-id: svn://svn.ircd-hybrid.org/svnroot/ircd-hybrid/branches/8.1.x@3042 82007160-df01-0410-b94d-b575c5fd34c7
Diffstat (limited to 'modules/core')
-rw-r--r--modules/core/m_mode.c9
-rw-r--r--modules/core/m_sjoin.c19
2 files changed, 11 insertions, 17 deletions
diff --git a/modules/core/m_mode.c b/modules/core/m_mode.c
index cb9f6a8..a4da839 100644
--- a/modules/core/m_mode.c
+++ b/modules/core/m_mode.c
@@ -180,7 +180,6 @@ ms_bmask(struct Client *client_p, struct Client *source_p, int parc, char *parv[
long mode_type;
int mlen, tlen;
int modecount = 0;
- int needcap = NOCAPS;
if ((chptr = hash_find_channel(parv[2])) == NULL)
return 0;
@@ -197,12 +196,10 @@ ms_bmask(struct Client *client_p, struct Client *source_p, int parc, char *parv[
case 'e':
mode_type = CHFL_EXCEPTION;
- needcap = CAP_EX;
break;
case 'I':
mode_type = CHFL_INVEX;
- needcap = CAP_IE;
break;
/* maybe we should just blindly propagate this? */
@@ -242,7 +239,7 @@ ms_bmask(struct Client *client_p, struct Client *source_p, int parc, char *parv[
sendto_channel_local(ALL_MEMBERS, 0, chptr, "%s %s",
modebuf, parabuf);
- sendto_server(client_p, needcap, CAP_TS6,
+ sendto_server(client_p, NOCAPS, CAP_TS6,
"%s %s", modebuf, parabuf);
mbuf = modebuf + mlen;
@@ -262,12 +259,12 @@ ms_bmask(struct Client *client_p, struct Client *source_p, int parc, char *parv[
{
*mbuf = *(pbuf - 1) = '\0';
sendto_channel_local(ALL_MEMBERS, 0, chptr, "%s %s", modebuf, parabuf);
- sendto_server(client_p, needcap, CAP_TS6,
+ sendto_server(client_p, NOCAPS, CAP_TS6,
"%s %s", modebuf, parabuf);
}
/* assumption here is that since the server sent BMASK, they are TS6, so they have an ID */
- sendto_server(client_p, CAP_TS6|needcap, NOCAPS, ":%s BMASK %lu %s %s :%s",
+ sendto_server(client_p, CAP_TS6, NOCAPS, ":%s BMASK %lu %s %s :%s",
source_p->id, (unsigned long)chptr->channelts, chptr->chname,
parv[3], parv[4]);
return 0;
diff --git a/modules/core/m_sjoin.c b/modules/core/m_sjoin.c
index 7213b2d..8d025f2 100644
--- a/modules/core/m_sjoin.c
+++ b/modules/core/m_sjoin.c
@@ -51,7 +51,7 @@ static int pargs;
static void set_final_mode(struct Mode *, struct Mode *);
static void remove_our_modes(struct Channel *, struct Client *);
static void remove_a_mode(struct Channel *, struct Client *, int, char);
-static void remove_ban_list(struct Channel *, struct Client *, dlink_list *, char, int);
+static void remove_ban_list(struct Channel *, struct Client *, dlink_list *, char);
/* ms_sjoin()
@@ -593,16 +593,13 @@ ms_sjoin(struct Client *client_p, struct Client *source_p,
if (HasID(source_p) && !keep_our_modes)
{
if (dlink_list_length(&chptr->banlist) > 0)
- remove_ban_list(chptr, client_p, &chptr->banlist,
- 'b', NOCAPS);
+ remove_ban_list(chptr, client_p, &chptr->banlist, 'b');
if (dlink_list_length(&chptr->exceptlist) > 0)
- remove_ban_list(chptr, client_p, &chptr->exceptlist,
- 'e', CAP_EX);
+ remove_ban_list(chptr, client_p, &chptr->exceptlist, 'e');
if (dlink_list_length(&chptr->invexlist) > 0)
- remove_ban_list(chptr, client_p, &chptr->invexlist,
- 'I', CAP_IE);
+ remove_ban_list(chptr, client_p, &chptr->invexlist, 'I');
clear_ban_cache(chptr);
}
@@ -774,14 +771,14 @@ remove_a_mode(struct Channel *chptr, struct Client *source_p,
/* remove_ban_list()
*
- * inputs - channel, source, list to remove, char of mode, caps required
+ * inputs - channel, source, list to remove, char of mode
* outputs - none
* side effects - given ban list is removed, modes are sent to local clients and
* non-ts6 servers linked through another uplink other than source_p
*/
static void
remove_ban_list(struct Channel *chptr, struct Client *source_p,
- dlink_list *list, char c, int cap)
+ dlink_list *list, char c)
{
char lmodebuf[MODEBUFLEN];
char lparabuf[IRCD_BUFSIZE];
@@ -809,7 +806,7 @@ remove_ban_list(struct Channel *chptr, struct Client *source_p,
*mbuf = *(pbuf - 1) = '\0';
sendto_channel_local(ALL_MEMBERS, 0, chptr, "%s %s",
lmodebuf, lparabuf);
- sendto_server(source_p, cap, CAP_TS6, "%s %s", lmodebuf, lparabuf);
+ sendto_server(source_p, NOCAPS, CAP_TS6, "%s %s", lmodebuf, lparabuf);
cur_len = mlen;
mbuf = lmodebuf + mlen;
@@ -828,7 +825,7 @@ remove_ban_list(struct Channel *chptr, struct Client *source_p,
*mbuf = *(pbuf - 1) = '\0';
sendto_channel_local(ALL_MEMBERS, 0, chptr, "%s %s", lmodebuf, lparabuf);
- sendto_server(source_p, cap, CAP_TS6, "%s %s", lmodebuf, lparabuf);
+ sendto_server(source_p, NOCAPS, CAP_TS6, "%s %s", lmodebuf, lparabuf);
}
static struct Message sjoin_msgtab =