]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
STABLE14-dont-fclose-null-20070514
authorErland Lewin <erland@lewin.nu>
Mon, 14 May 2007 20:27:49 +0000 (20:27 +0000)
committerDerrick Brashear <shadow@dementia.org>
Mon, 14 May 2007 20:27:49 +0000 (20:27 +0000)
we erroneously don't check for not null before fclose. fix it.

(1.4 only bug)

src/bozo/bosserver.c

index fbeae7125467644a4aa568ec68c642bf3e6e8961..bf94658e914dc002490d23e67072e85980c1f5d1 100644 (file)
@@ -1100,12 +1100,11 @@ bozo_Log(char *a, char *b, char *c, char *d, char *e, char *f)
            fprintf(bozo_logFile, "%s ", tdate);
            fprintf(bozo_logFile, a, b, c, d, e, f);
            fflush(bozo_logFile);
+           /* close so rm BosLog works */
+           fclose(bozo_logFile);
        } else {
            printf("%s ", tdate);
            printf(a, b, c, d, e, f);
        }
-
-       /* close so rm BosLog works */
-       fclose(bozo_logFile);
     }
 }