svn rev #25030: trunk/src/lib/gssapi/krb5/
ghudson@MIT.EDU
ghudson at MIT.EDU
Wed Jul 20 18:40:46 EDT 2011
http://src.mit.edu/fisheye/changelog/krb5/?cs=25030
Commit By: ghudson
Log Message:
Fix name initialization in gss_krb5int_import_cred.
If we're going to fake up a name, we have to initialize its lock. It
might be better to use kg_init_name(), but we don't have a context on
hand.
Changed Files:
U trunk/src/lib/gssapi/krb5/acquire_cred.c
Modified: trunk/src/lib/gssapi/krb5/acquire_cred.c
===================================================================
--- trunk/src/lib/gssapi/krb5/acquire_cred.c 2011-07-20 20:44:31 UTC (rev 25029)
+++ trunk/src/lib/gssapi/krb5/acquire_cred.c 2011-07-20 22:40:46 UTC (rev 25030)
@@ -834,6 +834,7 @@
struct acquire_cred_args args;
krb5_gss_name_rec name;
OM_uint32 time_rec;
+ krb5_error_code code;
assert(value->length == sizeof(*req));
@@ -846,6 +847,11 @@
if (req->keytab_principal) {
memset(&name, 0, sizeof(name));
+ code = k5_mutex_init(&name.lock);
+ if (code != 0) {
+ *minor_status = code;
+ return GSS_S_FAILURE;
+ }
name.princ = req->keytab_principal;
args.desired_name = (gss_name_t)&name;
}
More information about the cvs-krb5
mailing list