summaryrefslogtreecommitdiff
path: root/src/plugins/HPMHooking/HPMHooking_login.Hooks.inc
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/HPMHooking/HPMHooking_login.Hooks.inc')
-rw-r--r--src/plugins/HPMHooking/HPMHooking_login.Hooks.inc49
1 files changed, 11 insertions, 38 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking_login.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_login.Hooks.inc
index 375b78e11..18195af77 100644
--- a/src/plugins/HPMHooking/HPMHooking_login.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking_login.Hooks.inc
@@ -347,14 +347,14 @@ bool HP_login_check_password(const char *md5key, int passwdenc, const char *pass
}
return retVal___;
}
-int HP_login_lan_subnetcheck(uint32 ip) {
+uint32 HP_login_lan_subnet_check(uint32 ip) {
int hIndex = 0;
- int retVal___ = 0;
- if( HPMHooks.count.HP_login_lan_subnetcheck_pre ) {
- int (*preHookFunc) (uint32 *ip);
+ uint32 retVal___ = 0;
+ if( HPMHooks.count.HP_login_lan_subnet_check_pre ) {
+ uint32 (*preHookFunc) (uint32 *ip);
*HPMforce_return = false;
- for(hIndex = 0; hIndex < HPMHooks.count.HP_login_lan_subnetcheck_pre; hIndex++ ) {
- preHookFunc = HPMHooks.list.HP_login_lan_subnetcheck_pre[hIndex].func;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_login_lan_subnet_check_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_login_lan_subnet_check_pre[hIndex].func;
retVal___ = preHookFunc(&ip);
}
if( *HPMforce_return ) {
@@ -363,44 +363,17 @@ int HP_login_lan_subnetcheck(uint32 ip) {
}
}
{
- retVal___ = HPMHooks.source.login.lan_subnetcheck(ip);
+ retVal___ = HPMHooks.source.login.lan_subnet_check(ip);
}
- if( HPMHooks.count.HP_login_lan_subnetcheck_post ) {
- int (*postHookFunc) (int retVal___, uint32 *ip);
- for(hIndex = 0; hIndex < HPMHooks.count.HP_login_lan_subnetcheck_post; hIndex++ ) {
- postHookFunc = HPMHooks.list.HP_login_lan_subnetcheck_post[hIndex].func;
+ if( HPMHooks.count.HP_login_lan_subnet_check_post ) {
+ uint32 (*postHookFunc) (uint32 retVal___, uint32 *ip);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_login_lan_subnet_check_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_login_lan_subnet_check_post[hIndex].func;
retVal___ = postHookFunc(retVal___, &ip);
}
}
return retVal___;
}
-int HP_login_lan_config_read(const char *lancfgName) {
- int hIndex = 0;
- int retVal___ = 0;
- if( HPMHooks.count.HP_login_lan_config_read_pre ) {
- int (*preHookFunc) (const char *lancfgName);
- *HPMforce_return = false;
- for(hIndex = 0; hIndex < HPMHooks.count.HP_login_lan_config_read_pre; hIndex++ ) {
- preHookFunc = HPMHooks.list.HP_login_lan_config_read_pre[hIndex].func;
- retVal___ = preHookFunc(lancfgName);
- }
- if( *HPMforce_return ) {
- *HPMforce_return = false;
- return retVal___;
- }
- }
- {
- retVal___ = HPMHooks.source.login.lan_config_read(lancfgName);
- }
- if( HPMHooks.count.HP_login_lan_config_read_post ) {
- int (*postHookFunc) (int retVal___, const char *lancfgName);
- for(hIndex = 0; hIndex < HPMHooks.count.HP_login_lan_config_read_post; hIndex++ ) {
- postHookFunc = HPMHooks.list.HP_login_lan_config_read_post[hIndex].func;
- retVal___ = postHookFunc(retVal___, lancfgName);
- }
- }
- return retVal___;
-}
void HP_login_fromchar_accinfo(int fd, int account_id, int u_fd, int u_aid, int u_group, int map_fd, struct mmo_account *acc) {
int hIndex = 0;
if( HPMHooks.count.HP_login_fromchar_accinfo_pre ) {