(log_file): reset pointer to freed memory

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17214 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2006-04-24 15:09:27 +00:00
parent 4ba57d49e9
commit b24395ffde

View File

@@ -221,8 +221,10 @@ log_file(const char *timestr,
if(f->fd == NULL)
return;
fprintf(f->fd, "%s %s\n", timestr, msg);
if(f->keep_open == 0)
if(f->keep_open == 0) {
fclose(f->fd);
f->fd = NULL;
}
}
static void