ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/ircd-hybrid/trunk/src/send.c
(Generate patch)

Comparing ircd-hybrid-8/src/send.c (file contents):
Revision 1478 by michael, Sun Jul 22 14:44:07 2012 UTC vs.
Revision 1479 by michael, Sun Jul 22 17:02:48 2012 UTC

# Line 368 | Line 368 | sendto_one(struct Client *to, const char
368   */
369   void
370   sendto_channel_butone(struct Client *one, struct Client *from,
371 <                      struct Channel *chptr, const char *command,
371 >                      struct Channel *chptr, unsigned int type,
372                        const char *pattern, ...)
373   {
374    va_list alocal, aremote, auid;
# Line 379 | Line 379 | sendto_channel_butone(struct Client *one
379    dlink_node *ptr = NULL, *ptr_next = NULL;
380  
381    if (IsServer(from))
382 <    local_len = ircsprintf(local_buf, ":%s %s %s ",
383 <                           from->name, command, chptr->chname);
382 >    local_len = ircsprintf(local_buf, ":%s ",
383 >                           from->name);
384    else
385 <    local_len = ircsprintf(local_buf, ":%s!%s@%s %s %s ",
386 <                           from->name, from->username, from->host,
387 <                           command, chptr->chname);
388 <  remote_len = ircsprintf(remote_buf, ":%s %s %s ",
389 <                          from->name, command, chptr->chname);
390 <  uid_len = ircsprintf(uid_buf, ":%s %s %s ",
391 <                       ID(from), command, chptr->chname);
385 >    local_len = ircsprintf(local_buf, ":%s!%s@%s ",
386 >                           from->name, from->username, from->host);
387 >  remote_len = ircsprintf(remote_buf, ":%s ",
388 >                          from->name);
389 >  uid_len = ircsprintf(uid_buf, ":%s ",
390 >                       ID(from));
391  
392    va_start(alocal, pattern);
393    va_start(aremote, pattern);
# Line 407 | Line 406 | sendto_channel_butone(struct Client *one
406  
407    DLINK_FOREACH_SAFE(ptr, ptr_next, chptr->members.head)
408    {
409 <    struct Client *target_p = ((struct Membership *)ptr->data)->client_p;
409 >    struct Membership *ms = ptr->data;
410 >    struct Client *target_p = ms->client_p;
411  
412      assert(IsClient(target_p));
413  
414      if (IsDefunct(target_p) || HasUMode(target_p, UMODE_DEAF) || target_p->from == one)
415        continue;
416  
417 +    if (type != 0 && (ms->flags & type) == 0)
418 +      continue;
419 +
420      if (MyConnect(target_p))
421      {
422        if (target_p->localClient->serial != current_serial)

Diff Legend

Removed lines
+ Added lines
< Changed lines (old)
> Changed lines (new)