Ignore:
Timestamp:
02/12/07 05:52:32 (5 years ago)
Author:
wd
Message:

Get the base/existing IRC module compiling again. Clear out old junk.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ithildin/modules/ircd/addons/throttle.c

    r787 r801  
    6161static void destroy_throttle(throttle_t *); 
    6262 
    63 HOOK_FUNCTION(throttle_stage1_hook); 
     63HOOK_FUNCTION(throttle_connected_hook); 
    6464HOOK_FUNCTION(throttle_conf_hook); 
    6565HOOK_FUNCTION(throttle_timer_hook); 
     
    106106#define THROTTLE_ERRMSG                                                        \ 
    107107    "Your host is trying to (re)connect too fast -- throttled." 
    108 HOOK_FUNCTION(throttle_stage1_hook) { 
     108HOOK_FUNCTION(throttle_connected_hook) { 
    109109    connection_t *cp = (connection_t *)data; 
    110110    throttle_t *tp = find_throttle(isock_raddr(cp->sock)); 
     
    164164 
    165165    if (tp->banned + len >= me.now)  { 
    166         if ((ap = find_acl(ACL_STAGE_CONNECT, ACL_DENY, cp->host, 
     166        if ((ap = find_acl(ACL_STAGE_CONNECTED, ACL_DENY, cp->host, 
    167167                        throttle_acl_type, ACL_DEFAULT_RULE, NULL, NULL)) == NULL) { 
    168             ap = create_acl(ACL_STAGE_CONNECT, ACL_DENY, cp->host, 
     168            ap = create_acl(ACL_STAGE_CONNECTED, ACL_DENY, cp->host, 
    169169                    throttle_acl_type, ACL_DEFAULT_RULE); 
    170170            ap->reason = strdup(THROTTLE_ERRMSG); 
     
    272272    LIST_ALLOC(throttle.list); 
    273273 
    274     add_hook_before(ircd.events.stage1_connect, throttle_stage1_hook, 
    275             acl_stage1_hook); 
     274    add_hook_before(ircd.events.connection_connected, 
     275            throttle_connected_stage_hook, acl_connected_stage_hook); 
    276276    add_hook(me.events.read_conf, throttle_conf_hook); 
    277277 
     
    288288    LIST_FREE(throttle.list); 
    289289 
    290     remove_hook(ircd.events.stage1_connect, throttle_stage1_hook); 
     290    remove_hook(ircd.events.connection_connected, 
     291            throttle_connected_stage_hook); 
    291292    remove_hook(me.events.read_conf, throttle_conf_hook); 
    292293} 
Note: See TracChangeset for help on using the changeset viewer.