From e48f3450112b9770a55deb44d4331e7aa6d64c71 Mon Sep 17 00:00:00 2001 From: Tom Yu Date: Mon, 18 Jul 2005 23:32:18 +0000 Subject: [PATCH] pullup from trunk ticket: 3098 version_fixed: 1.4.2 component: krb5-libs git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-4@17308 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/krb5/ccache/ChangeLog | 4 ++++ src/lib/krb5/ccache/cc_file.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/lib/krb5/ccache/ChangeLog b/src/lib/krb5/ccache/ChangeLog index 47e675928..e015116a5 100644 --- a/src/lib/krb5/ccache/ChangeLog +++ b/src/lib/krb5/ccache/ChangeLog @@ -1,3 +1,7 @@ +2005-06-15 Ken Raeburn + + * cc_file.c (dereference): Fix test is list-walking loop. + 2005-01-13 Ken Raeburn * cc_file.c (struct _krb5_fcc_data): Fields disk_file_lock, diff --git a/src/lib/krb5/ccache/cc_file.c b/src/lib/krb5/ccache/cc_file.c index 0529e4b21..cc8bccef9 100644 --- a/src/lib/krb5/ccache/cc_file.c +++ b/src/lib/krb5/ccache/cc_file.c @@ -1461,10 +1461,11 @@ static krb5_error_code dereference(krb5_context context, krb5_fcc_data *data) kerr = k5_mutex_lock(&krb5int_cc_file_mutex); if (kerr) return kerr; - for (fccsp = &fccs; *fccsp == NULL; fccsp = &(*fccsp)->next) + for (fccsp = &fccs; *fccsp != NULL; fccsp = &(*fccsp)->next) if ((*fccsp)->data == data) break; assert(*fccsp != NULL); + assert((*fccsp)->data == data); (*fccsp)->refcount--; if ((*fccsp)->refcount == 0) { struct fcc_set *temp; -- 2.26.2