From 435b9a5e3cca3afa2fb8849c87c7e0f775f62282 Mon Sep 17 00:00:00 2001 From: Greg Hudson Date: Thu, 12 Feb 2009 19:38:08 +0000 Subject: [PATCH] In krb5_rc_io_open_internal, d->fn is always set for the cleanup handler, so do not check it. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@21982 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/krb5/rcache/rc_io.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/lib/krb5/rcache/rc_io.c b/src/lib/krb5/rcache/rc_io.c index 02a45a455..8d7d986da 100644 --- a/src/lib/krb5/rcache/rc_io.c +++ b/src/lib/krb5/rcache/rc_io.c @@ -295,12 +295,10 @@ krb5_rc_io_open_internal(krb5_context context, krb5_rc_iostuff *d, char *fn, cleanup: if (retval) { - if (d->fn) { - if (!do_not_unlink) - (void) unlink(d->fn); - free(d->fn); - d->fn = NULL; - } + if (!do_not_unlink) + (void) unlink(d->fn); + free(d->fn); + d->fn = NULL; if (d->fd >= 0) (void) close(d->fd); } -- 2.26.2