]> jfr.im git - solanum.git/blobdiff - ircd/s_serv.c
modules/m_sasl.c: use IsSecure() instead of IsSSL()
[solanum.git] / ircd / s_serv.c
index 0ab96ec7e88af175cc0fa42164cc6e0ec0ccabb7..7ce1daf24ff9c5a60c3b575d639ae9ca5bca6e5e 100644 (file)
@@ -474,13 +474,8 @@ burst_ban(struct Client *client_p)
 {
        rb_dlink_node *ptr;
        struct ConfItem *aconf;
-       const char *type, *oper;
-       /* +5 for !,@,{,} and null */
-       char operbuf[NICKLEN + USERLEN + HOSTLEN + HOSTLEN + 5];
-       char *p;
-       size_t melen;
+       const char *type;
 
-       melen = strlen(me.name);
        RB_DLINK_FOREACH(ptr, prop_bans.head)
        {
                aconf = ptr->data;
@@ -498,24 +493,6 @@ burst_ban(struct Client *client_p)
                        default:
                                continue;
                }
-               oper = aconf->info.oper;
-               if(aconf->flags & CONF_FLAGS_MYOPER)
-               {
-                       /* Our operator{} names may not be meaningful
-                        * to other servers, so rewrite to our server
-                        * name.
-                        */
-                       rb_strlcpy(operbuf, aconf->info.oper, sizeof operbuf);
-                       p = strrchr(operbuf, '{');
-                       if (p != NULL &&
-                                       operbuf + sizeof operbuf - p > (ptrdiff_t)(melen + 2))
-                       {
-                               memcpy(p + 1, me.name, melen);
-                               p[melen + 1] = '}';
-                               p[melen + 2] = '\0';
-                               oper = operbuf;
-                       }
-               }
                sendto_one(client_p, ":%s BAN %s %s %s %lu %d %d %s :%s%s%s",
                                me.id,
                                type,
@@ -523,7 +500,7 @@ burst_ban(struct Client *client_p)
                                (unsigned long)aconf->created,
                                (int)(aconf->hold - aconf->created),
                                (int)(aconf->lifetime - aconf->created),
-                               oper,
+                               aconf->info.oper,
                                aconf->passwd,
                                aconf->spasswd ? "|" : "",
                                aconf->spasswd ? aconf->spasswd : "");
@@ -645,11 +622,18 @@ burst_TS6(struct Client *client_p)
                                   use_id(target_p),
                                   target_p->user->away);
 
-               if(IsOper(target_p) && target_p->user && target_p->user->opername && target_p->user->privset)
-                       sendto_one(client_p, ":%s OPER %s %s",
-                                       use_id(target_p),
-                                       target_p->user->opername,
-                                       target_p->user->privset->name);
+               if (IsOper(target_p) && target_p->user && target_p->user->opername)
+               {
+                       if (target_p->user->privset)
+                               sendto_one(client_p, ":%s OPER %s %s",
+                                               use_id(target_p),
+                                               target_p->user->opername,
+                                               target_p->user->privset->name);
+                       else
+                               sendto_one(client_p, ":%s OPER %s",
+                                               use_id(target_p),
+                                               target_p->user->opername);
+               }
 
                hclientinfo.target = target_p;
                call_hook(h_burst_client, &hclientinfo);