Use krb5_cc_get_type() to get the type, dont assume typename_arg is set

Patch from Johan Gadsjö via Joakim Fallsjö
This commit is contained in:
Love Hornquist Astrand
2009-09-24 07:19:33 -07:00
parent 8ec3c9dcba
commit 98f2421134

View File

@@ -138,7 +138,7 @@ main(int argc, char **argv)
if (name == NULL)
krb5_errx(context, 1, "Generated credential cache have no name");
snprintf(tf, sizeof(tf), "%s:%s", typename_arg, name);
snprintf(tf, sizeof(tf), "%s:%s", krb5_cc_get_type(context, id), name);
ret = krb5_cc_close(context, id);
if (ret)