Added AOPER_AUTO to allow SA opers to automatically be set UMODE +Aa
authorMatthew Mondor <mmondor@pulsar-zone.net>
Fri, 14 Jan 2005 13:15:33 +0000 (13:15 +0000)
committerMatthew Mondor <mmondor@pulsar-zone.net>
Fri, 14 Jan 2005 13:15:33 +0000 (13:15 +0000)
RUBIKS-CHANGES
include/config.h
src/s_user.c

index a2ac817..99aab7b 100644 (file)
@@ -9,6 +9,8 @@ rubiks-ircd-0-0-2       Based on bahamut 1.8.3 release (BAHAMUT-1-8-3)
   - Added NO_TILDE in include/config.h to prevent ~ from being prefixed
     to usernames for which ident could not be retreived, can only be used
     if DO_IDENT is unset (default for rubiks-ircd)
+  - Added AOPER_AUTO to include/config.h which allows SA opers to
+    automatically be set with UNAME +Aa
 
 - Added cleaning of zlib/Makefile and zlib/zconf.h which was missing
   in bahamut release
index c215129..8c18f3d 100644 (file)
@@ -18,7 +18,7 @@
  *
  */
 
-/* $Id: config.h,v 1.9 2005/01/14 07:50:00 mwiggins Exp $ */
+/* $Id: config.h,v 1.10 2005/01/14 13:15:33 mmondor Exp $ */
 
 #ifndef        __config_include__
 #define        __config_include__
  */
 #define NO_TILDE
 
+/* AOPER_AUTO
+ * Should opers which have A rights automatically be granted UMODE +A
+ */
+#define AOPER_AUTO
+
 /* SSL
  * SSL support stolen from fqircd
  */
index 4f81f55..c41dd1a 100644 (file)
@@ -21,7 +21,7 @@
  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
-/* $Id: s_user.c,v 1.7 2005/01/14 07:50:01 mwiggins Exp $ */
+/* $Id: s_user.c,v 1.8 2005/01/14 13:15:33 mmondor Exp $ */
 
 #include "struct.h"
 #include "common.h"
@@ -2716,6 +2716,12 @@ int m_oper(aClient *cptr, aClient *sptr, int parc, char *parv[])
         sptr->umode |= UMODE_I;
         sendto_serv_butone(cptr, ":%s MODE %s :+I", parv[0], parv[0]);
 #endif
+#ifdef AOPER_AUTO
+       if (OPIsSAdmin(sptr)) {
+           sptr->umode |= UMODE_A | UMODE_a;
+           sendto_serv_butone(cptr, ":%s MODE %s :+Aa", parv[0], parv[0]);
+       }
+#endif
         Count.oper++;
         if (IsMe(cptr))
             sendto_one(sptr, rpl_str(RPL_YOUREOPER), me.name, parv[0]);
@@ -2783,6 +2789,10 @@ int m_oper(aClient *cptr, aClient *sptr, int parc, char *parv[])
         sptr->umode|=(UMODE_s|UMODE_g|UMODE_w|UMODE_n);
 #endif
         sptr->oflag = aoper->flags;
+#ifdef AOPER_AUTO
+       if (OPIsSAdmin(sptr))
+           sptr->umode |= (UMODE_A | UMODE_a);
+#endif
         Count.oper++;
         add_to_list(&oper_list, sptr);
         throttle_remove(oper_ip);