diff options
Diffstat (limited to 'src/libstrongswan/library.c')
-rw-r--r-- | src/libstrongswan/library.c | 28 |
1 files changed, 20 insertions, 8 deletions
diff --git a/src/libstrongswan/library.c b/src/libstrongswan/library.c index 07d08fa51..cb8d43052 100644 --- a/src/libstrongswan/library.c +++ b/src/libstrongswan/library.c @@ -1,4 +1,5 @@ /* + * Copyright (C) 2009 Tobias Brunner * Copyright (C) 2008 Martin Willi * Hochschule fuer Technik Rapperswil * @@ -12,7 +13,7 @@ * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * for more details. * - * $Id: library.c 4311 2008-08-28 16:27:48Z martin $ + * $Id: library.c 4936 2009-03-12 18:07:32Z tobias $ */ #include "library.h" @@ -95,13 +96,24 @@ void library_init(char *settings) pfh = printf_hook_create(); this->public.printf_hook = pfh; - pfh->add_handler(pfh, 'b', mem_get_printf_hooks()); - pfh->add_handler(pfh, 'B', chunk_get_printf_hooks()); - pfh->add_handler(pfh, 'D', identification_get_printf_hooks()); - pfh->add_handler(pfh, 'H', host_get_printf_hooks()); - pfh->add_handler(pfh, 'N', enum_get_printf_hooks()); - pfh->add_handler(pfh, 'T', time_get_printf_hooks()); - pfh->add_handler(pfh, 'V', time_delta_get_printf_hooks()); + pfh->add_handler(pfh, 'b', mem_printf_hook, + PRINTF_HOOK_ARGTYPE_POINTER, PRINTF_HOOK_ARGTYPE_INT, + PRINTF_HOOK_ARGTYPE_END); + pfh->add_handler(pfh, 'B', chunk_printf_hook, + PRINTF_HOOK_ARGTYPE_POINTER, PRINTF_HOOK_ARGTYPE_END); + pfh->add_handler(pfh, 'D', identification_printf_hook, + PRINTF_HOOK_ARGTYPE_POINTER, PRINTF_HOOK_ARGTYPE_END); + pfh->add_handler(pfh, 'H', host_printf_hook, + PRINTF_HOOK_ARGTYPE_POINTER, PRINTF_HOOK_ARGTYPE_END); + pfh->add_handler(pfh, 'N', enum_printf_hook, + PRINTF_HOOK_ARGTYPE_POINTER, PRINTF_HOOK_ARGTYPE_INT, + PRINTF_HOOK_ARGTYPE_END); + pfh->add_handler(pfh, 'T', time_printf_hook, + PRINTF_HOOK_ARGTYPE_POINTER, PRINTF_HOOK_ARGTYPE_INT, + PRINTF_HOOK_ARGTYPE_END); + pfh->add_handler(pfh, 'V', time_delta_printf_hook, + PRINTF_HOOK_ARGTYPE_POINTER, PRINTF_HOOK_ARGTYPE_POINTER, + PRINTF_HOOK_ARGTYPE_END); this->public.crypto = crypto_factory_create(); this->public.creds = credential_factory_create(); |