Change profile code over to new thread macros, and enable data sharing always
authorKen Raeburn <raeburn@mit.edu>
Sun, 14 Mar 2004 04:27:08 +0000 (04:27 +0000)
committerKen Raeburn <raeburn@mit.edu>
Sun, 14 Mar 2004 04:27:08 +0000 (04:27 +0000)
commit7b6a6167c1dd23bf551e34c43362fac658227ce1
tree9ab6f3b2fd5fbfdf3910d39089b09abf5208fb3e
parentf93537966df048a1b9a6eb67d1f40bb0d77dca72
Change profile code over to new thread macros, and enable data sharing always

* prof_int.h: Include k5-thread.h.  Don't include sys/types.h and pthread.h.
(SHARE_TREE_DATA): Always define.
(USE_PTHREADS): Don't define.
(prof_mutex_lock, prof_mutex_unlock): Deleted.
(struct global_shared_profile_data): Change mutex to use k5_mutex_t instead of
pthread_mutex_t.
(g_shared_trees_mutex): Don't conditionalize on USE_PTHREADS.
* prof_file.c (krb5int_profile_shared_data): Initialize mutex.
(profile_open_file, profile_dereference_data): Use new mutex macros.  Check
return status when locking.  Fix a potential memory leak in an error case.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16163 dc483132-0cff-0310-8789-dd5450dbe970
src/util/profile/ChangeLog
src/util/profile/prof_file.c
src/util/profile/prof_int.h