summaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
authorHercules.ws <dev@herc.ws>2016-08-22 03:34:24 +0200
committerHerculesWSAPI <dev@herc.ws>2016-08-22 03:34:24 +0200
commit22e4f01fda1d9f61b0e663eb9e4edf8bd73b6e91 (patch)
treeb1c25f9c7fd62cf2fec844f3c34e10c98cfd275d /src/plugins
parent6be58f54fcae8115bd4ffb6b3abb1bbf65248797 (diff)
downloadhercules-22e4f01fda1d9f61b0e663eb9e4edf8bd73b6e91.tar.gz
hercules-22e4f01fda1d9f61b0e663eb9e4edf8bd73b6e91.tar.bz2
hercules-22e4f01fda1d9f61b0e663eb9e4edf8bd73b6e91.tar.xz
hercules-22e4f01fda1d9f61b0e663eb9e4edf8bd73b6e91.zip
HPM Hooks Update
Signed-off-by: HerculesWSAPI <dev@herc.ws>
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/HPMHooking/HPMHooking.Defs.inc2
-rw-r--r--src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc4
-rw-r--r--src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc1
-rw-r--r--src/plugins/HPMHooking/HPMHooking_char.Hooks.inc27
4 files changed, 34 insertions, 0 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking.Defs.inc b/src/plugins/HPMHooking/HPMHooking.Defs.inc
index 4061bd4d4..9968d1d18 100644
--- a/src/plugins/HPMHooking/HPMHooking.Defs.inc
+++ b/src/plugins/HPMHooking/HPMHooking.Defs.inc
@@ -2876,6 +2876,8 @@ typedef void (*HPMHOOK_pre_inter_final) (void);
typedef void (*HPMHOOK_post_inter_final) (void);
typedef bool (*HPMHOOK_pre_inter_config_read) (const char **filename, bool *imported);
typedef bool (*HPMHOOK_post_inter_config_read) (bool retVal___, const char *filename, bool imported);
+typedef bool (*HPMHOOK_pre_inter_config_read_log) (const char **filename, const struct config_t **config, bool *imported);
+typedef bool (*HPMHOOK_post_inter_config_read_log) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
typedef bool (*HPMHOOK_pre_inter_config_read_connection) (const char **filename, const struct config_t **config, bool *imported);
typedef bool (*HPMHOOK_post_inter_config_read_connection) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
#endif // CHAR_INTER_H
diff --git a/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc
index 44b56143f..836e51f3f 100644
--- a/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc
+++ b/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc
@@ -552,6 +552,8 @@ struct {
struct HPMHookPoint *HP_inter_final_post;
struct HPMHookPoint *HP_inter_config_read_pre;
struct HPMHookPoint *HP_inter_config_read_post;
+ struct HPMHookPoint *HP_inter_config_read_log_pre;
+ struct HPMHookPoint *HP_inter_config_read_log_post;
struct HPMHookPoint *HP_inter_config_read_connection_pre;
struct HPMHookPoint *HP_inter_config_read_connection_post;
struct HPMHookPoint *HP_inter_mail_sql_init_pre;
@@ -2055,6 +2057,8 @@ struct {
int HP_inter_final_post;
int HP_inter_config_read_pre;
int HP_inter_config_read_post;
+ int HP_inter_config_read_log_pre;
+ int HP_inter_config_read_log_post;
int HP_inter_config_read_connection_pre;
int HP_inter_config_read_connection_post;
int HP_inter_mail_sql_init_pre;
diff --git a/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc
index 35f9044d5..047373f77 100644
--- a/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc
+++ b/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc
@@ -302,6 +302,7 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(inter->parse_frommap, HP_inter_parse_frommap) },
{ HP_POP(inter->final, HP_inter_final) },
{ HP_POP(inter->config_read, HP_inter_config_read) },
+ { HP_POP(inter->config_read_log, HP_inter_config_read_log) },
{ HP_POP(inter->config_read_connection, HP_inter_config_read_connection) },
/* inter_mail_interface */
{ HP_POP(inter_mail->sql_init, HP_inter_mail_sql_init) },
diff --git a/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc
index 3669b2da8..63afcab3c 100644
--- a/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc
@@ -7060,6 +7060,33 @@ bool HP_inter_config_read(const char *filename, bool imported) {
}
return retVal___;
}
+bool HP_inter_config_read_log(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_inter_config_read_log_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_inter_config_read_log_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_inter_config_read_log_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.inter.config_read_log(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_inter_config_read_log_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_inter_config_read_log_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_inter_config_read_log_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
bool HP_inter_config_read_connection(const char *filename, const struct config_t *config, bool imported) {
int hIndex = 0;
bool retVal___ = false;