Code

logfile plugin: Interpret `(notification_t *)->time == 0' as `now'.
authorFlorian Forster <octo@leeloo.lan.home.verplant.org>
Mon, 23 Feb 2009 14:38:29 +0000 (15:38 +0100)
committerFlorian Forster <octo@leeloo.lan.home.verplant.org>
Mon, 23 Feb 2009 14:38:29 +0000 (15:38 +0100)
src/logfile.c

index 8e98c0478e925de5ad3a6e1372206e88af79dddf..03af7a3fe4369f2b614517613ac3c7108f52b7e1 100644 (file)
@@ -187,7 +187,8 @@ static int logfile_notification (const notification_t *n,
 
        buf[sizeof (buf) - 1] = '\0';
 
-       logfile_print (buf, n->time);
+       logfile_print (buf,
+                       (n->time > 0) ? n->time : time (NULL));
 
        return (0);
 } /* int logfile_notification */