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

Comparing ircd-hybrid-7.3/src/s_conf.c (file contents):
Revision 1123 by michael, Sun Feb 6 21:57:50 2011 UTC vs.
Revision 1147 by michael, Thu Jul 28 20:14:29 2011 UTC

# Line 2365 | Line 2365 | get_oper_name(const struct Client *clien
2365    struct AccessItem *aconf;
2366  
2367    /* +5 for !,@,{,} and null */
2368 <  static char buffer[NICKLEN+USERLEN+HOSTLEN+HOSTLEN+5];
2368 >  static char buffer[NICKLEN + USERLEN + HOSTLEN + HOSTLEN + 5];
2369  
2370    if (MyConnect(client_p))
2371    {
# Line 2376 | Line 2376 | get_oper_name(const struct Client *clien
2376  
2377        if (IsConfOperator(aconf))
2378        {
2379 <        ircsprintf(buffer, "%s!%s@%s{%s}", client_p->name,
2380 <                   client_p->username, client_p->host,
2381 <                   conf->name);
2379 >        snprintf(buffer, sizeof(buffer), "%s!%s@%s{%s}", client_p->name,
2380 >                 client_p->username, client_p->host, conf->name);
2381          return buffer;
2382        }
2383      }
# Line 2389 | Line 2388 | get_oper_name(const struct Client *clien
2388      assert(0); /* Oper without oper conf! */
2389    }
2390  
2391 <  ircsprintf(buffer, "%s!%s@%s{%s}", client_p->name,
2392 <             client_p->username, client_p->host, client_p->servptr->name);
2391 >  snprintf(buffer, sizeof(buffer), "%s!%s@%s{%s}", client_p->name,
2392 >           client_p->username, client_p->host, client_p->servptr->name);
2393    return buffer;
2394   }
2395  
# Line 2442 | Line 2441 | read_conf_files(int cold)
2441    fbclose(conf_parser_ctx.conf_file);
2442  
2443    add_isupport("NETWORK", ServerInfo.network_name, -1);
2444 <  ircsprintf(chanmodes, "b%s%s:%d", ConfigChannel.use_except ? "e" : "",
2445 <             ConfigChannel.use_invex ? "I" : "", ConfigChannel.max_bans);
2444 >  snprintf(chanmodes, sizeof(chanmodes), "b%s%s:%d",
2445 >           ConfigChannel.use_except ? "e" : "",
2446 >           ConfigChannel.use_invex ? "I" : "", ConfigChannel.max_bans);
2447    add_isupport("MAXLIST", chanmodes, -1);
2448    add_isupport("MAXTARGETS", NULL, ConfigFileEntry.max_targets);
2449 +
2450    if (ConfigChannel.disable_local_channels)
2451      add_isupport("CHANTYPES", "#", -1);
2452    else
2453      add_isupport("CHANTYPES", "#&", -1);
2454 <  ircsprintf(chanlimit, "%s:%d", ConfigChannel.disable_local_channels ? "#" : "#&",
2455 <             ConfigChannel.max_chans_per_user);
2454 >
2455 >  snprintf(chanlimit, sizeof(chanlimit), "%s:%d",
2456 >           ConfigChannel.disable_local_channels ? "#" : "#&",
2457 >           ConfigChannel.max_chans_per_user);
2458    add_isupport("CHANLIMIT", chanlimit, -1);
2459 <  ircsprintf(chanmodes, "%s%s%s", ConfigChannel.use_except ? "e" : "",
2460 <             ConfigChannel.use_invex ? "I" : "", "b,k,l,imnpst");
2459 >  snprintf(chanmodes, sizeof(chanmodes), "%s%s%s",
2460 >           ConfigChannel.use_except ? "e" : "",
2461 >           ConfigChannel.use_invex ? "I" : "", "b,k,l,imnpst");
2462    add_isupport("CHANNELLEN", NULL, LOCAL_CHANNELLEN);
2463 +
2464    if (ConfigChannel.use_except)
2465      add_isupport("EXCEPTS", "e", -1);
2466    if (ConfigChannel.use_invex)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines