diff options
| author | Ken Raeburn <raeburn@mit.edu> | 2004-08-13 04:02:35 +0000 |
|---|---|---|
| committer | Ken Raeburn <raeburn@mit.edu> | 2004-08-13 04:02:35 +0000 |
| commit | 56a7231e867b8bb17e1852a8d04fe6e3f5b62e33 (patch) | |
| tree | 3b3e107dbed9f4dee4467974a3ce70086570c0c1 /src/include/ChangeLog | |
| parent | 4286789a65f3b8005434a4e8feee89a787643e76 (diff) | |
| download | krb5-56a7231e867b8bb17e1852a8d04fe6e3f5b62e33.tar.gz krb5-56a7231e867b8bb17e1852a8d04fe6e3f5b62e33.tar.xz krb5-56a7231e867b8bb17e1852a8d04fe6e3f5b62e33.zip | |
Only open a credential cache file once, even if multiple krb5_ccache objects
refer to it. (This does NOT yet take care of the problem of multiple threads
wanting to use OS-level advisory locks, which at least on UNIX are per-process
and not per-thread.)
* cc_file.c (krb5_fcc_close_file): Change first argument to be an fcc-data
pointer, not a krb5_ccache. All calls changed.
(struct fcc_set): Add a refcount member. (Definition accidentally introduced
without comment in an earlier patch.)
(krb5int_cc_file_mutex, fccs): New variables, for managing a global list of
open credential cache files.
(dereference): New function, with most of old close/destroy operations.
Decrements reference count and only frees the object and removes it from the
global list if the refcount hits zero.
(krb5_fcc_close, krb5_fcc_destroy): Call dereference.
(krb5_fcc_resolve): If a file cache is already open with the same file name,
increment its reference count and don't create a new one. When a new one is
created, add it to the global list.
* cc-int.h (krb5int_cc_file_mutex): Declare.
* ccbase.c (krb5int_cc_initialize): Initialize it.
(krb5int_cc_finalize): Destroy it, and krb5int_mcc_mutex.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16662 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/include/ChangeLog')
0 files changed, 0 insertions, 0 deletions
