$NetBSD: patch-ab,v 1.3 2003/01/31 12:57:08 tron Exp $

--- wmbiff/wmbiff.c.orig	Sat Jan 25 07:02:17 2003
+++ wmbiff/wmbiff.c	Thu Jan 30 13:30:38 2003
@@ -24,6 +24,14 @@
 #include <errno.h>
 #include <string.h>
 
+#if defined(FreeBSD) || defined(__NetBSD__) || defined(__OpenBSD__)
+#include <paths.h>
+#endif
+
+#ifndef _PATH_MAILDIR
+#define _PATH_MAILDIR "/var/mail"
+#endif
+
 #include "../wmgeneral/wmgeneral.h"
 #include "../wmgeneral/misc.h"
 
@@ -363,8 +371,8 @@
 			strcpy(mbox[0].path, m);
 		} else if ((m = getenv("USER")) != NULL) {
 			/* we are using MAIL environment var. type mbox */
-			DMA(DEBUG_INFO, "Using /var/mail/%s.\n", m);
-			strcpy(mbox[0].path, "/var/mail/");
+			DMA(DEBUG_INFO, "Using " _PATH_MAILDIR "/%s.\n", m);
+			strcpy(mbox[0].path, _PATH_MAILDIR);
 			strcat(mbox[0].path, m);
 		} else {
 			DMA(DEBUG_ERROR, "Cannot open config file '%s' nor use the "
