/*
* Empire - A multi-player, client/server Internet based war game.
- * Copyright (C) 1986-2011, Dave Pare, Jeff Bailey, Thomas Ruschak,
+ * Copyright (C) 1986-2013, Dave Pare, Jeff Bailey, Thomas Ruschak,
* Ken Stevens, Steve McClure, Markus Armbruster
*
* Empire is free software: you can redistribute it and/or modify
* journal.c: Log a journal of events to a file
*
* Known contributors to this file:
- * Markus Armbruster, 2004-2011
+ * Markus Armbruster, 2004-2012
* Ron Koenderink, 2008
*/
journal_entry_vstart(char *fmt, va_list ap)
{
time_t now;
+ empth_t *self;
if (!journal)
return;
time(&now);
+ self = empth_self();
fprintf(journal, "%.24s %10.10s ",
- ctime(&now), empth_name(empth_self()));
+ ctime(&now), self ? empth_name(self) : "Main");
vfprintf(journal, fmt, ap);
}