Remove self-op code for Apass/Upass joins.
authorMichael Poole <mdpoole@troilus.org>
Sun, 5 Feb 2006 00:50:22 +0000 (00:50 +0000)
committerMichael Poole <mdpoole@troilus.org>
Sun, 5 Feb 2006 00:50:22 +0000 (00:50 +0000)
git-svn-id: file:///home/klmitch/undernet-ircu/undernet-ircu-svn/ircu2/branches/u2_10_12_branch@1614 c9e4aea6-c8fd-4c43-8297-357d70d61c8c

ChangeLog
ircd/m_join.c
ircd/m_mode.c

index 280b4ecd5e45ee2fadd3f3255ac3acdbc361819e..8c935b85c9202d5769cba0aa11dd3a607d0e2d3b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2006-02-04  Michael Poole <mdpoole@troilus.org>
+
+       * ircd/m_join.c (m_join): Remove #if 0 code and update comment.
+
+       * ircd/m_mode.c (ms_mode): Remove self-op support.
+
 2006-01-12  Michael Poole <mdpoole@troilus.org>
 
        * include/patchlevel.h (PATCHLEVEL): Update for 2.10.12.pre06.
index e2e3e4f38151eec9ccad0e0838c99edcc5af0290..33d857fa9ad67a18893e54539522b235baea8cfa 100644 (file)
@@ -246,17 +246,13 @@ int m_join(struct Client *cptr, struct Client *sptr, int parc, char *parv[])
       joinbuf_join(&join, chptr, flags);
       if (flags & CHFL_CHANOP) {
         struct ModeBuf mbuf;
-#if 0
-        /* Send a MODE to the other servers. If the user used the A/U pass,
-        * let his server op him, otherwise let him op himself. */
-       modebuf_init(&mbuf, chptr->mode.apass[0] ? &me : sptr, cptr, chptr, MODEBUF_DEST_SERVER);
-#else
        /* Always let the server op him: this is needed on a net with older servers
           because they 'destruct' channels immediately when they become empty without
           sending out a DESTRUCT message. As a result, they would always bounce a mode
-          (as HACK(2)) when the user ops himself. */
+          (as HACK(2)) when the user ops himself.
+           (There is also no particularly good reason to have the user op himself.)
+        */
        modebuf_init(&mbuf, &me, cptr, chptr, MODEBUF_DEST_SERVER);
-#endif
        modebuf_mode_client(&mbuf, MODE_ADD | MODE_CHANOP, sptr,
                             chptr->mode.apass[0] ? ((flags & CHFL_CHANNEL_MANAGER) ? 0 : 1) : MAXOPLEVEL);
        modebuf_flush(&mbuf);
index 051fc630e7d606fbeeb2f14498374d9ee1ad8664..c994569e878c5d7897c0dbb16bfc3f1ddf3fa71c 100644 (file)
@@ -191,9 +191,7 @@ ms_mode(struct Client *cptr, struct Client *sptr, int parc, char *parv[])
                MODE_PARSE_FORCE),  /* And force it to be accepted */
                NULL);
   } else {
-    if (!(member = find_member_link(chptr, sptr))
-        /* Allow people to op themselves on an empty channel. */
-        || (!IsChanOp(member) && chptr->users > 1)) {
+    if (!(member = find_member_link(chptr, sptr))) {
       modebuf_init(&mbuf, sptr, cptr, chptr,
                   (MODEBUF_DEST_SERVER |  /* Send mode to server */
                    MODEBUF_DEST_HACK2  |  /* Send a HACK(2) message */