From: Ken Raeburn Date: Sat, 3 Apr 2004 01:23:51 +0000 (+0000) Subject: * keytab.c (krb5_ktkdb_get_entry): Don't use local variable "context" until X-Git-Tag: krb5-1.4-beta1~505 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=b50f29a4ebc41d43f07a3191259ca915ecadb544;p=krb5.git * keytab.c (krb5_ktkdb_get_entry): Don't use local variable "context" until after it's been set. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16229 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/lib/kdb/ChangeLog b/src/lib/kdb/ChangeLog index 49ae47865..84bc49e45 100644 --- a/src/lib/kdb/ChangeLog +++ b/src/lib/kdb/ChangeLog @@ -1,3 +1,8 @@ +2004-04-02 Ken Raeburn + + * keytab.c (krb5_ktkdb_get_entry): Don't use local variable + "context" until after it's been set. + 2003-12-13 Ken Raeburn * keytab.c (krb5_ktkdb_get_name): New function. diff --git a/src/lib/kdb/keytab.c b/src/lib/kdb/keytab.c index 4d5894d08..77215f410 100644 --- a/src/lib/kdb/keytab.c +++ b/src/lib/kdb/keytab.c @@ -130,7 +130,7 @@ krb5_ktkdb_get_entry(in_context, id, principal, kvno, enctype, entry) krb5_db_entry db_entry; krb5_boolean more = 0; int n = 0; - int xrealm_tgt = is_xrealm_tgt(context, principal); + int xrealm_tgt; int similar; if (ktkdb_ctx) @@ -138,6 +138,8 @@ krb5_ktkdb_get_entry(in_context, id, principal, kvno, enctype, entry) else context = in_context; + xrealm_tgt = is_xrealm_tgt(context, principal); + /* Open database */ /* krb5_db_init(context); */ if ((kerror = krb5_db_open_database(context)))