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

Comparing ircd-hybrid/trunk/src/channel.c (file contents):
Revision 9085 by michael, Sun Oct 13 09:52:35 2019 UTC vs.
Revision 9086 by michael, Mon Oct 14 15:45:15 2019 UTC

# Line 147 | Line 147 | channel_send_members(struct Client *clie
147                       const char *modebuf, const char *parabuf)
148   {
149    dlink_node *node;
150 <  char buf[IRCD_BUFSIZE] = "";
150 >  char buf[IRCD_BUFSIZE];
151    int tlen;              /* length of text to append */
152    char *t, *start;       /* temp char pointer */
153  
# Line 210 | Line 210 | channel_send_mask_list(struct Client *cl
210                         const dlink_list *list, const char flag)
211   {
212    dlink_node *node;
213 <  char mbuf[IRCD_BUFSIZE] = "";
214 <  char pbuf[IRCD_BUFSIZE] = "";
213 >  char mbuf[IRCD_BUFSIZE];
214 >  char pbuf[IRCD_BUFSIZE];
215    int tlen, mlen, cur_len;
216    char *pp = pbuf;
217  
# Line 419 | Line 419 | void
419   channel_member_names(struct Client *client_p, struct Channel *channel, bool show_eon)
420   {
421    dlink_node *node;
422 <  char buf[IRCD_BUFSIZE + 1] = "";
423 <  char *t = NULL, *start = NULL;
422 >  char buf[IRCD_BUFSIZE + 1];
423    int tlen = 0;
424    bool is_member = IsMember(client_p, channel);
425    bool multi_prefix = HasCap(client_p, CAP_MULTI_PREFIX) != 0;
# Line 430 | Line 429 | channel_member_names(struct Client *clie
429  
430    if (PubChannel(channel) || is_member == true)
431    {
432 <    t = buf + snprintf(buf, sizeof(buf), numeric_form(RPL_NAMREPLY),
433 <                       me.name, client_p->name,
434 <                       channel_pub_or_secret(channel), channel->name);
436 <    start = t;
432 >    char *t = buf + snprintf(buf, sizeof(buf), numeric_form(RPL_NAMREPLY), me.name, client_p->name,
433 >                             channel_pub_or_secret(channel), channel->name);
434 >    char *start = t;
435  
436      DLINK_FOREACH(node, channel->members.head)
437      {
# Line 770 | Line 768 | int
768   can_send(struct Channel *channel, struct Client *client_p,
769           struct ChannelMember *member, const char *message, bool notice)
770   {
771 <  const struct ResvItem *resv = NULL;
771 >  const struct ResvItem *resv;
772  
773    if (IsServer(client_p) || HasFlag(client_p, FLAGS_SERVICE))
774      return CAN_SEND_OPV;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines