$NetBSD: patch-af,v 1.5 2014/04/24 14:48:44 schmonz Exp $ time_t may be 64-bit. --- src/drv_maildir.c.orig 2013-12-18 17:58:26.000000000 +0000 +++ src/drv_maildir.c @@ -1167,7 +1167,7 @@ maildir_store_msg( store_t *gctx, msg_da int ret, fd, bl, uid; char buf[_POSIX_PATH_MAX], nbuf[_POSIX_PATH_MAX], fbuf[NUM_FLAGS + 3], base[128]; - bl = nfsnprintf( base, sizeof(base), "%ld.%d_%d.%s", (long)time( 0 ), Pid, ++MaildirCount, Hostname ); + bl = nfsnprintf( base, sizeof(base), "%lld.%d_%d.%s", (long long int)time( 0 ), Pid, ++MaildirCount, Hostname ); if (!to_trash) { #ifdef USE_DB if (ctx->db) { @@ -1347,8 +1347,8 @@ maildir_trash_msg( store_t *gctx, messag for (;;) { nfsnprintf( buf, sizeof(buf), "%s/%s/%s", gctx->path, subdirs[gmsg->status & M_RECENT], msg->base ); s = strstr( msg->base, ":2," ); - nfsnprintf( nbuf, sizeof(nbuf), "%s/%s/%ld.%d_%d.%s%s", ctx->trash, - subdirs[gmsg->status & M_RECENT], (long)time( 0 ), Pid, ++MaildirCount, Hostname, s ? s : "" ); + nfsnprintf( nbuf, sizeof(nbuf), "%s/%s/%lld.%d_%d.%s%s", ctx->trash, + subdirs[gmsg->status & M_RECENT], (long long int)time( 0 ), Pid, ++MaildirCount, Hostname, s ? s : "" ); if (!rename( buf, nbuf )) break; if (!stat( buf, &st )) {