From: Ken Raeburn Date: Wed, 9 Feb 2005 02:19:45 +0000 (+0000) Subject: * krb5_libinit.c (krb5int_lib_init, krb5int_lib_fini): If SHOW_INITFINI_FUNCS X-Git-Tag: ms-bug-test-20060525~340 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=70138da6e4f2d2cad7ce68f8671b9126572dcecf;p=krb5.git * krb5_libinit.c (krb5int_lib_init, krb5int_lib_fini): If SHOW_INITFINI_FUNCS is defined, print tracing messages. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@17095 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/lib/krb5/ChangeLog b/src/lib/krb5/ChangeLog index dbf97ec1a..97862beb0 100644 --- a/src/lib/krb5/ChangeLog +++ b/src/lib/krb5/ChangeLog @@ -1,5 +1,8 @@ 2005-02-08 Ken Raeburn + * krb5_libinit.c (krb5int_lib_init, krb5int_lib_fini): If + SHOW_INITFINI_FUNCS is defined, print tracing messages. + * Makefile.in (LIBINITFUNC, LIBFINIFUNC): Define. 2005-01-17 Jeffrey Altman diff --git a/src/lib/krb5/krb5_libinit.c b/src/lib/krb5/krb5_libinit.c index ece79cfc7..126dc2e50 100644 --- a/src/lib/krb5/krb5_libinit.c +++ b/src/lib/krb5/krb5_libinit.c @@ -31,6 +31,10 @@ int krb5int_lib_init(void) { int err; +#ifdef SHOW_INITFINI_FUNCS + printf("krb5int_lib_init\n"); +#endif + #if !USE_BUNDLE_ERROR_STRINGS add_error_table(&et_krb5_error_table); add_error_table(&et_kv5m_error_table); @@ -66,8 +70,14 @@ krb5_error_code krb5int_initialize_library (void) void krb5int_lib_fini(void) { - if (!INITIALIZER_RAN(krb5int_lib_init) || PROGRAM_EXITING()) + if (!INITIALIZER_RAN(krb5int_lib_init) || PROGRAM_EXITING()) { + printf("krb5int_lib_fini: skipping\n"); return; + } + +#ifdef SHOW_INITFINI_FUNCS + printf("krb5int_lib_fini\n"); +#endif k5_mutex_destroy(&krb5int_us_time_mutex);