/*
* Everything which needs some logging...
+ * $Id$
*/
+#include "sysdep.h"
#include <stdlib.h>
#include <unistd.h>
#include <stdio.h>
#include <ctype.h>
#include <string.h>
#include <errno.h>
-#include <pthread.h>
#include <syslog.h>
#include "citadel.h"
#include "server.h"
time(&now);
fp = fopen("citadel.log", "a");
- fprintf(fp, "%ld|%u|%s\n", now, lrtype, name);
- fclose(fp);
+ if (fp != NULL) {
+ fprintf(fp, "%ld|%u|%s\n", (long)now, lrtype, name);
+ fclose(fp);
}
+}