$OpenBSD: patch-common_argus_util_c,v 1.2 2010/04/15 19:15:19 steven Exp $

work around reading the wrong piece of memory on sparc64.

--- common/argus_util.c.orig	Mon Aug 17 16:35:18 2009
+++ common/argus_util.c	Sat Apr 10 12:33:38 2010
@@ -1916,11 +1916,12 @@ print_time(struct timeval *tvp)
    char timeZoneBuf[32];
    char *retn = ArgusPrintTimeBuf, *ptr;
    struct tm *tm, tmbuf;
+   time_t sec = (time_t) tvp->tv_sec;
 
    bzero (timeZoneBuf, sizeof(timeZoneBuf));
    bzero (ArgusPrintTimeBuf, sizeof(ArgusPrintTimeBuf));
 
-   if ((tm = localtime_r ((time_t *)&tvp->tv_sec, &tmbuf)) != NULL) {
+   if ((tm = localtime_r (&sec, &tmbuf)) != NULL) {
 #if !defined(HAVE_STRFTIME)
       snprintf (retn, 32, "%9d", (int) tvp->tv_sec);
 #else
