ports/80106: [PATCH] mail/maildrop flock() failure

David Lay dsl at webize.com.au
Tue Apr 19 14:00:50 UTC 2005


>Number:         80106
>Category:       ports
>Synopsis:       [PATCH] mail/maildrop flock() failure
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Apr 19 14:00:49 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator:     David Lay
>Release:        FreeBSD 4.11-RELEASE-p3 i386
>Organization:
Webize
>Environment:
System: FreeBSD mayhem.webize.com.au 4.11-RELEASE-p3 FreeBSD 4.11-RELEASE-p3 #16: Sun Apr 17 01:25:55 EST 2005 root at mayhem.webize.com.au:/usr/obj/usr/src/sys/MAYHEM i386

maildrop-1.8.0_2

>Description:
	Maildrop exits with "flock() failed" when an attempting to route messages to /dev/null.

>How-To-Repeat:

	~/.mailfilter:

            to "tmp/devnull"

>Fix:

diff -Nur /usr/ports/mail/maildrop/files/patch-filelock.C maildrop/files/patch-filelock.C
--- /usr/ports/mail/maildrop/files/patch-filelock.C	Thu Jan  1 10:00:00 1970
+++ maildrop/files/patch-filelock.C	Fri Apr 15 13:12:31 2005
@@ -0,0 +1,11 @@
+--- maildrop/filelock.C.orig	Sat Apr 29 03:17:45 2000
++++ maildrop/filelock.C	Fri Apr 15 13:09:25 2005
+@@ -64,7 +64,7 @@
+ 		// you're writing to a device file, you know what you're doing.
+ 
+ 		if (fstat(fd, &stat_buf) >= 0 && (
+-			S_ISREG(stat_buf.st_mode) || S_ISDIR(stat_buf.st_mode)))
++			S_ISCHR(stat_buf.st_mode) || S_ISBLK(stat_buf.st_mode)))
+ 		{
+ 			return;
+ 		}

>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list