(get_cell_and_realm): plug a memory leak, found by IBM checker.

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16942 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2006-04-02 01:24:52 +00:00
parent 4b2323bd43
commit 4fd7055bdf

View File

@@ -94,6 +94,7 @@ get_cell_and_realm (krb5_context context,
f = fopen (AFS_SERVERMAGICKRBCONF, "r");
if (f != NULL) {
if (fgets (buf, sizeof(buf), f) == NULL) {
free (d->cell);
fclose (f);
krb5_set_error_string (context, "no realm in %s",
AFS_SERVERMAGICKRBCONF);