Commit 7ff8e23f authored by Russ Allbery's avatar Russ Allbery

Use krb5_xfree instead of krb5_free_unparsed_name

Call krb5_xfree if available instead of krb5_free_unparsed_name in a
few more places.
parent e2820e42
......@@ -120,11 +120,19 @@ queue_prefix(krb5_context ctx, krb5_principal principal, const char *domain,
length = strlen(user) + strlen(domain) + strlen(operation) + 4;
prefix = malloc(length);
if (prefix == NULL) {
#ifdef HAVE_KRB5_XFREE
krb5_xfree(user);
#else
krb5_free_unparsed_name(ctx, user);
#endif
return NULL;
}
snprintf(prefix, length, "%s-%s-%s-", user, domain, operation);
#ifdef HAVE_KRB5_XFREE
krb5_xfree(user);
#else
krb5_free_unparsed_name(ctx, user);
#endif
return prefix;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment