From 7880c2eacaa45196b83a9032371f487f6fe312e4 Mon Sep 17 00:00:00 2001 From: William Jon McCann Date: Fri, 19 Oct 2007 16:46:43 -0400 Subject: check for oldest being null --- tools/ck-history.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/ck-history.c b/tools/ck-history.c index 23a87af..b6ee5d2 100644 --- a/tools/ck-history.c +++ b/tools/ck-history.c @@ -241,8 +241,10 @@ generate_report_last_compat (void) } oldest = g_list_first (all_events); - oldest_event = oldest->data; - g_print ("\nLog begins %s", ctime (&oldest_event->timestamp.tv_sec)); + if (oldest != NULL) { + oldest_event = oldest->data; + g_print ("\nLog begins %s", ctime (&oldest_event->timestamp.tv_sec)); + } } static void -- cgit