]> jfr.im git - irc/rqf/shadowircd.git/blobdiff - src/send.c
Added m_cycle and added it to all the appropriate locations.
[irc/rqf/shadowircd.git] / src / send.c
index 84b7fb7132e29cb2f4af648a5697eb7be5e20219..db98c579fd8e1a6963cf5a01cf7cd76b9a114a3d 100644 (file)
@@ -85,10 +85,7 @@ _send_linebuf(struct Client *to, buf_head_t *linebuf)
                             get_sendq(to));
                }
 
-               if(IsClient(to))
-                       to->flags |= FLAGS_SENDQEX;
-
-               dead_link(to);
+               dead_link(to, 1);
                return -1;
        }
        else
@@ -200,7 +197,7 @@ send_queued(struct Client *to)
 
                if(retlen == 0 || (retlen < 0 && !rb_ignore_errno(errno)))
                {
-                       dead_link(to);
+                       dead_link(to, 0);
                        return;
                }
        }
@@ -542,8 +539,6 @@ sendto_channel_opmod(struct Client *one, struct Client *source_p,
                     struct Channel *chptr, const char *command,
                     const char *text)
 {
-       static char buf[BUFSIZE];
-       va_list args;
        buf_head_t rb_linebuf_local;
        buf_head_t rb_linebuf_old;
        buf_head_t rb_linebuf_new;
@@ -589,7 +584,7 @@ sendto_channel_opmod(struct Client *one, struct Client *source_p,
                if(IsIOError(target_p->from) || target_p->from == one)
                        continue;
 
-               if((msptr->flags & CHFL_CHANOP) == 0)
+               if(!is_any_op(msptr))
                        continue;
 
                if(IsDeaf(target_p))
@@ -651,7 +646,12 @@ sendto_channel_local(int type, struct Channel *chptr, const char *pattern, ...)
                if(IsIOError(target_p))
                        continue;
 
-               if(type && ((msptr->flags & type) == 0))
+               if(type == ONLY_OPERS)
+               {
+                       if(!IsOper(target_p))
+                               continue;
+               }
+               else if(type && ((msptr->flags & type) == 0))
                        continue;
 
                _send_linebuf(target_p, &linebuf);