X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fafb-hook.c;h=592f92a423ded5ff3d715198c4cab51fa67b5074;hb=5ef271effacb83552f9ea56572c751c2f5a556b6;hp=6b6553016404607b1d761c51d9257d852bc51b0b;hpb=e39610f8c9b2e6bbb8a460f7d7ccccbc5161b4ed;p=src%2Fapp-framework-binder.git diff --git a/src/afb-hook.c b/src/afb-hook.c index 6b655301..592f92a4 100644 --- a/src/afb-hook.c +++ b/src/afb-hook.c @@ -913,6 +913,11 @@ static void hook_api_on_event_handler_after_cb(void *closure, const struct afb_h _hook_api_(export, "on_event_handler[%s].after(%s, %d, %s)", pattern, event, event_x2, json_object_to_json_string_ext(object, JSON_C_TO_STRING_NOSLASHESCAPE)); } +static void hook_api_settings_cb(void *closure, const struct afb_hookid *hookid, const struct afb_export *export, struct json_object *object) +{ + _hook_api_(export, "settings -> %s", json_object_to_json_string_ext(object, JSON_C_TO_STRING_NOSLASHESCAPE)); +} + static struct afb_hook_api_itf hook_api_default_itf = { .hook_api_event_broadcast_before = hook_api_event_broadcast_before_cb, .hook_api_event_broadcast_after = hook_api_event_broadcast_after_cb, @@ -952,6 +957,7 @@ static struct afb_hook_api_itf hook_api_default_itf = { .hook_api_delete_api = hook_api_delete_api_cb, .hook_api_on_event_handler_before = hook_api_on_event_handler_before_cb, .hook_api_on_event_handler_after = hook_api_on_event_handler_after_cb, + .hook_api_settings = hook_api_settings_cb, }; /****************************************************************************** @@ -1189,6 +1195,12 @@ void afb_hook_api_on_event_handler_after(const struct afb_export *export, const _HOOK_API_2_(on_event_handler, on_event_handler_after, export, event, event_x2, object, pattern); } +struct json_object *afb_hook_api_settings(const struct afb_export *export, struct json_object *object) +{ + _HOOK_API_(settings, export, object); + return object; +} + /****************************************************************************** * section: hooking export *****************************************************************************/