read dead code, cid#5
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24132 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
24
kcm/cache.c
24
kcm/cache.c
@@ -182,27 +182,17 @@ kcm_ccache_alloc(krb5_context context,
|
|||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Then try and find an empty slot
|
* Create an enpty slot for us.
|
||||||
* XXX we need to recycle slots for this to actually do anything
|
|
||||||
*/
|
*/
|
||||||
if (slot == NULL) {
|
if (slot == NULL) {
|
||||||
for (; p != NULL; p = p->next) {
|
slot = (kcm_ccache_data *)malloc(sizeof(*slot));
|
||||||
if ((p->flags & KCM_FLAGS_VALID) == 0) {
|
|
||||||
slot = p;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (slot == NULL) {
|
if (slot == NULL) {
|
||||||
slot = (kcm_ccache_data *)malloc(sizeof(*slot));
|
ret = KRB5_CC_NOMEM;
|
||||||
if (slot == NULL) {
|
goto out;
|
||||||
ret = KRB5_CC_NOMEM;
|
|
||||||
goto out;
|
|
||||||
}
|
|
||||||
slot->next = ccache_head;
|
|
||||||
HEIMDAL_MUTEX_init(&slot->mutex);
|
|
||||||
new_slot = 1;
|
|
||||||
}
|
}
|
||||||
|
slot->next = ccache_head;
|
||||||
|
HEIMDAL_MUTEX_init(&slot->mutex);
|
||||||
|
new_slot = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
slot->name = strdup(name);
|
slot->name = strdup(name);
|
||||||
|
Reference in New Issue
Block a user