* et/error_message.c (com_err_initialize, com_err_terminate): If
authorKen Raeburn <raeburn@mit.edu>
Wed, 9 Feb 2005 02:18:19 +0000 (02:18 +0000)
committerKen Raeburn <raeburn@mit.edu>
Wed, 9 Feb 2005 02:18:19 +0000 (02:18 +0000)
SHOW_INITFINI_FUNCS is defined, print tracing messages.

* profile/prof_file.c (profile_library_initializer, profile_library_finalizer):
If SHOW_INITFINI_FUNCS is defined, print tracing messages.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@17094 dc483132-0cff-0310-8789-dd5450dbe970

src/util/et/ChangeLog
src/util/et/error_message.c
src/util/profile/ChangeLog
src/util/profile/prof_file.c

index bec74072234bc37634cc85fe73510326fda9af31..e4c906b9f61e311680d244014cdec2fe1a1664db 100644 (file)
@@ -1,3 +1,8 @@
+2005-02-08  Ken Raeburn  <raeburn@mit.edu>
+
+       * error_message.c (com_err_initialize, com_err_terminate): If
+       SHOW_INITFINI_FUNCS is defined, print tracing messages.
+
 2005-01-17  Jeffrey Altman <jaltman@mit.edu>
 
         * error_message.c: implement library unload cleanup of mutexes
index cb76b2a37520ed279eb653fd4d4254394923c537..b7f8947d2926e4add0c4be53841e76e7ae3f9069 100644 (file)
@@ -45,6 +45,9 @@ MAKE_FINI_FUNCTION(com_err_terminate);
 int com_err_initialize(void)
 {
     int err;
+#ifdef SHOW_INITFINI_FUNCS
+    printf("com_err_initialize\n");
+#endif
     terminated = 0;
     err = k5_mutex_finish_init(&et_list_lock);
     if (err)
@@ -61,8 +64,15 @@ int com_err_initialize(void)
 void com_err_terminate(void)
 {
     struct dynamic_et_list *e, *enext;
-    if (! INITIALIZER_RAN(com_err_initialize) || PROGRAM_EXITING())
+    if (! INITIALIZER_RAN(com_err_initialize) || PROGRAM_EXITING()) {
+#ifdef SHOW_INITFINI_FUNCS
+       printf("com_err_terminate: skipping\n");
+#endif
        return;
+    }
+#ifdef SHOW_INITFINI_FUNCS
+    printf("com_err_terminate\n");
+#endif
     k5_key_delete(K5_KEY_COM_ERR);
     k5_mutex_destroy(&com_err_hook_lock);
     k5_mutex_lock(&et_list_lock);
index 985664014dcc36964126a76c4755d6784c4f91e5..f5f860271e54c580b56d15477afcbb5bccc53b59 100644 (file)
@@ -1,3 +1,9 @@
+2005-02-08  Ken Raeburn  <raeburn@mit.edu>
+
+       * prof_file.c (profile_library_initializer,
+       profile_library_finalizer): If SHOW_INITFINI_FUNCS is defined,
+       print tracing messages.
+
 2005-01-13  Ken Raeburn  <raeburn@mit.edu>
 
        * prof_file.c (profile_free_file_data): Destroy mutex before
index 9b0048c9cbb18f2f8709e067644164a3db114652..6201dd3516f668c9c7bdbfc989aa8d5e70d096d9 100644 (file)
@@ -49,6 +49,9 @@ MAKE_FINI_FUNCTION(profile_library_finalizer);
 
 int profile_library_initializer(void)
 {
+#ifdef SHOW_INITFINI_FUNCS
+    printf("profile_library_initializer\n");
+#endif
 #if !USE_BUNDLE_ERROR_STRINGS
     add_error_table(&et_prof_error_table);
 #endif
@@ -56,8 +59,15 @@ int profile_library_initializer(void)
 }
 void profile_library_finalizer(void)
 {
-    if (! INITIALIZER_RAN(profile_library_initializer) || PROGRAM_EXITING())
+    if (! INITIALIZER_RAN(profile_library_initializer) || PROGRAM_EXITING()) {
+#ifdef SHOW_INITFINI_FUNCS
+       printf("profile_library_finalizer: skipping\n");
+#endif
        return;
+    }
+#ifdef SHOW_INITFINI_FUNCS
+    printf("profile_library_finalizer\n");
+#endif
     k5_mutex_destroy(&g_shared_trees_mutex);
 #if !USE_BUNDLE_ERROR_STRINGS
     remove_error_table(&et_prof_error_table);