mirror of
https://github.com/matrix-construct/construct
synced 2024-12-28 00:14:07 +01:00
Automated merge with http://angelforce.ru:8000
This commit is contained in:
commit
faefd28ac1
5 changed files with 24 additions and 16 deletions
|
@ -42,10 +42,11 @@ void free_cachefile(struct cachefile *);
|
|||
void load_help(void);
|
||||
|
||||
void send_user_motd(struct Client *);
|
||||
void send_oper_motd(struct Client *);
|
||||
void cache_user_motd(void);
|
||||
|
||||
struct Dictionary;
|
||||
extern struct Dictionary *help_dict_oper;
|
||||
struct Dictionary;
|
||||
extern struct Dictionary *help_dict_oper;
|
||||
extern struct Dictionary *help_dict_user;
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -118,7 +118,7 @@ ilog(ilogfile dest, const char *format, ...)
|
|||
return;
|
||||
|
||||
va_start(args, format);
|
||||
ircvsnprintf(buf, sizeof(buf), format, args);
|
||||
rb_vsnprintf(buf, sizeof(buf), format, args);
|
||||
va_end(args);
|
||||
|
||||
rb_snprintf(buf2, sizeof(buf2), "%s %s\n", smalldate(), buf);
|
||||
|
|
|
@ -63,13 +63,16 @@ static rb_bh *nd_heap = NULL;
|
|||
static void expire_temp_rxlines(void *unused);
|
||||
static void expire_nd_entries(void *unused);
|
||||
|
||||
struct ev_entry *expire_nd_entries_ev = NULL;
|
||||
struct ev_entry *expire_temp_rxlines_ev = NULL;
|
||||
|
||||
void
|
||||
init_s_newconf(void)
|
||||
{
|
||||
tgchange_tree = New_Patricia(PATRICIA_BITS);
|
||||
nd_heap = rb_bh_create(sizeof(struct nd_entry), ND_HEAP_SIZE);
|
||||
eventAddIsh("expire_nd_entries", expire_nd_entries, NULL, 30);
|
||||
eventAddIsh("expire_temp_rxlines", expire_temp_rxlines, NULL, 60);
|
||||
tgchange_tree = rb_new_patricia(PATRICIA_BITS);
|
||||
nd_heap = rb_bh_create(sizeof(struct nd_entry), ND_HEAP_SIZE, "nd_heap");
|
||||
expire_nd_entries_ev = rb_event_addish("expire_nd_entries", expire_nd_entries, NULL, 30);
|
||||
expire_temp_rxlines_ev = rb_event_addish("expire_temp_rxlines", expire_temp_rxlines, NULL, 60);
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -203,7 +206,7 @@ propagate_generic(struct Client *source_p, const char *command,
|
|||
va_list args;
|
||||
|
||||
va_start(args, format);
|
||||
ircvsnprintf(buffer, sizeof(buffer), format, args);
|
||||
rb_vsnprintf(buffer, sizeof(buffer), format, args);
|
||||
va_end(args);
|
||||
|
||||
sendto_match_servs(source_p, target, cap, NOCAPS,
|
||||
|
@ -224,7 +227,7 @@ cluster_generic(struct Client *source_p, const char *command,
|
|||
rb_dlink_node *ptr;
|
||||
|
||||
va_start(args, format);
|
||||
ircvsnprintf(buffer, sizeof(buffer), format, args);
|
||||
rb_vsnprintf(buffer, sizeof(buffer), format, args);
|
||||
va_end(args);
|
||||
|
||||
RB_DLINK_FOREACH(ptr, cluster_conf_list.head)
|
||||
|
@ -796,7 +799,7 @@ void
|
|||
add_tgchange(const char *host)
|
||||
{
|
||||
tgchange *target;
|
||||
patricia_node_t *pnode;
|
||||
rb_patricia_node_t *pnode;
|
||||
|
||||
if(find_tgchange(host))
|
||||
return;
|
||||
|
@ -816,9 +819,9 @@ add_tgchange(const char *host)
|
|||
tgchange *
|
||||
find_tgchange(const char *host)
|
||||
{
|
||||
patricia_node_t *pnode;
|
||||
rb_patricia_node_t *pnode;
|
||||
|
||||
if((pnode = match_exact_string(tgchange_tree, host)))
|
||||
if((pnode = rb_match_exact_string(tgchange_tree, host)))
|
||||
return pnode->data;
|
||||
|
||||
return NULL;
|
||||
|
|
|
@ -284,7 +284,7 @@ count_memory(struct Client *source_p)
|
|||
|
||||
class_count = rb_dlink_list_length(&class_list) + 1;
|
||||
|
||||
count_linebuf_memory(&linebuf_count, &linebuf_memory_used);
|
||||
rb_count_rb_linebuf_memory(&linebuf_count, &linebuf_memory_used);
|
||||
|
||||
sendto_one_numeric(source_p, RPL_STATSDEBUG,
|
||||
"z :Users %u(%lu) Invites %u(%lu)",
|
||||
|
|
|
@ -290,10 +290,14 @@ register_local_user(struct Client *client_p, struct Client *source_p, const char
|
|||
/* Apply nick override */
|
||||
if(*source_p->preClient->spoofnick)
|
||||
{
|
||||
char note[NICKLEN + 10];
|
||||
|
||||
del_from_client_hash(source_p->name, source_p);
|
||||
strlcpy(source_p->name, source_p->preClient->spoofnick, NICKLEN + 1);
|
||||
add_to_client_hash(source_p->name, source_p);
|
||||
rb_note(source_p->localClient->F->fd, "Nick: %s", source_p->name);
|
||||
|
||||
rb_snprintf(note, NICKLEN + 10, "Nick: %s", source_p->name);
|
||||
rb_note(source_p->localClient->F, note);
|
||||
}
|
||||
|
||||
if(!valid_hostname(source_p->host))
|
||||
|
|
Loading…
Reference in a new issue