Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 3 Jun 2004 02:02:57 -0600
From:      Phil Oleson <oz@nixil.net>
To:        Pav Lucistnik <pav@FreeBSD.org>
Cc:        freebsd-gnats-submit@FreeBSD.org
Subject:   Re: ports/67504: mail/milter-greylist: error applying patch
Message-ID:  <20040603080257.GA21271@nixil.net>
In-Reply-To: <200406022128.i52LSX5i090966@freefall.freebsd.org>
References:  <200406022128.i52LSX5i090966@freefall.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--envbJBWh7q8WU6mo
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Let's just upgrade this package to the latest version which includes the reload patch
plus other added features... and avoids the RCS tag problem I'm having.

Phil.

On Wed, Jun 02, 2004 at 02:28:33PM -0700, Pav Lucistnik wrote:
> Synopsis: mail/milter-greylist: error applying patch
> 
> State-Changed-From-To: open->feedback
> State-Changed-By: pav
> State-Changed-When: Wed Jun 2 14:27:16 PDT 2004
> State-Changed-Why: 
> How exactly have you obtained your ports? I don't see
> expanded Id neither in my cvsup ports tree, files checked
> out of CVS or on CVSweb
> 
> http://www.freebsd.org/cgi/cvsweb.cgi/ports/mail/milter-greylist/files/patch-conf.c?rev=1.1&content-type=text/x-cvsweb-markup
> 
> 
> Responsible-Changed-From-To: freebsd-ports-bugs->pav
> Responsible-Changed-By: pav
> Responsible-Changed-When: Wed Jun 2 14:27:16 PDT 2004
> Responsible-Changed-Why: 
> My business
> 
> http://www.freebsd.org/cgi/query-pr.cgi?pr=67504

--envbJBWh7q8WU6mo
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="milter-greylist.patch"

diff -rN milter-greylist.orig/Makefile milter-greylist/Makefile
5c5
< # $FreeBSD: ports/mail/milter-greylist/Makefile,v 1.2 2004/05/31 22:56:57 pav Exp $
---
> # $FreeBSD$
9,10c9
< PORTVERSION=	1.2.2
< PORTREVISION=	1
---
> PORTVERSION=	1.3.8
diff -rN milter-greylist.orig/distinfo milter-greylist/distinfo
1,2c1,2
< MD5 (milter-greylist-1.2.2.tgz) = 7c313a482cec2b4e406eefe121c1e5e7
< SIZE (milter-greylist-1.2.2.tgz) = 88297
---
> MD5 (milter-greylist-1.3.8.tgz) = c31172a904212706dee8795f351e918a
> SIZE (milter-greylist-1.3.8.tgz) = 91830
diff -rN milter-greylist.orig/files/patch-Makefile.in milter-greylist/files/patch-Makefile.in
1,2c1,2
< --- Makefile.in.orig	Sat Apr  3 11:26:11 2004
< +++ Makefile.in	Tue May 25 23:04:47 2004
---
> --- Makefile.in.orig	Wed Jun  2 23:54:36 2004
> +++ Makefile.in	Wed Jun  2 23:54:40 2004
7c7
< -CFLAGS= 	@CFLAGS@ -D_BSD_SOURCE -Wall -ansi
---
> -CFLAGS= 	@CFLAGS@ -D_BSD_SOURCE
12c12
< +LIBS= 		-lmilter
---
> +LIBS= 		@LIBS@ -lmilter
16c16
< @@ -66,34 +66,20 @@
---
> @@ -67,34 +67,20 @@
27,30c27
< -	${INSTALL} -d 755 ${BINDIR}
< -	${INSTALL} -d 755 ${MANDIR}/man8
< -	${INSTALL} -d 755 ${MANDIR}/man5
< +	${INSTALL} -d -m 755 ${BINDIR}
---
>  	${INSTALL} -d -m 755 ${BINDIR}
32,33c29,30
< +	${INSTALL} -d -m 755 ${MANDIR}/man8
< +	${INSTALL} -d -m 755 ${MANDIR}/man5
---
>  	${INSTALL} -d -m 755 ${MANDIR}/man8
>  	${INSTALL} -d -m 755 ${MANDIR}/man5
diff -rN milter-greylist.orig/files/patch-conf.c milter-greylist/files/patch-conf.c
1,71d0
< --- conf.c.orig	Fri Apr  2 17:06:52 2004
< +++ conf.c	Mon May 31 16:58:06 2004
< @@ -34,7 +34,7 @@
<  #ifdef HAVE_SYS_CDEFS_H
<  #include <sys/cdefs.h>
<  #ifdef __RCSID
< -__RCSID("$Id: conf.c,v 1.15 2004/04/02 15:06:52 manu Exp $");
< +__RCSID("$Id: conf.c,v 1.15 (sigsev patch) 2004/04/02 15:06:52 manu Exp $");
<  #endif
<  #endif
<  
< @@ -83,6 +83,8 @@
<  conf_load(void) 	/* exceptlist must be write-locked */
<  {
<  	FILE *stream;
< +	pthread_t tid;
< +	pthread_attr_t attr;
<  
<  	/*
<  	 * Reset the configuration to its default 
< @@ -100,8 +102,49 @@
<  		return;
<  	}
<  
< +	/*
< +	 * On some platforms, the thread stack limit is too low and
< +	 * conf_parse will get a SIGSEGV because it overflows the
< +	 * stack.
< +	 *
< +	 * In order to fix this, we spawn a new thread just for 
< +	 * parsing the config file, and we request a stack big 
< +	 * enough to hold the parser data. 2 MB seems okay.
< +	 */
< +
<  	conf_in = stream;
< -	conf_parse();
< +
< +	if (pthread_attr_init(&attr) != 0) {
< +		syslog(LOG_ERR, "pthread_attr_init failed: %s", 
< +		strerror(errno));
< +		exit(EX_OSERR);
< +	}
< +
< +	if (pthread_attr_setstacksize(&attr, 2 * 1024 * 1024) != 0) {
< +		syslog(LOG_ERR, "pthread_attr_setstacksize failed: %s",
< +		strerror(errno));
< +		exit(EX_OSERR);
< +	}
< +
< +	if (pthread_create(&tid, &attr, 
< +		(void *(*)(void *))conf_parse, NULL) != 0) {
< +		syslog(LOG_ERR, "pthread_create failed: %s", 
< +		strerror(errno));
< +		exit(EX_OSERR);
< +	}
< +
< +	if (pthread_join(tid, NULL) != 0) {
< +		syslog(LOG_ERR, "pthread_join failed: %s",
< +		strerror(errno));
< +		exit(EX_OSERR);
< +	}
< +
< +	if (pthread_attr_destroy(&attr) != 0) {
< +		syslog(LOG_ERR, "pthread_attr_destroy failed: %s",
< +		strerror(errno));
< +		exit(EX_OSERR);
< +	}
< +
<  	fclose(stream);
<  
<  	(void)gettimeofday(&conffile_modified, NULL);
diff -rN milter-greylist.orig/files/patch-dump.c milter-greylist/files/patch-dump.c
1,10d0
< --- dump.c.orig	Wed Mar 31 19:02:08 2004
< +++ dump.c	Thu Apr 29 15:12:53 2004
< @@ -53,6 +53,7 @@
<  #include <sysexits.h>
<  #include <syslog.h>
<  #include <time.h>
< +#include <unistd.h>
<  
<  #include <sys/types.h>
<  #include <sys/param.h>
diff -rN milter-greylist.orig/files/patch-dump.h milter-greylist/files/patch-dump.h
1,2c1,2
< --- dump.h.orig	Thu May  6 15:54:01 2004
< +++ dump.h	Tue May 25 22:48:33 2004
---
> --- dump.h.orig	Wed Jun  2 23:57:21 2004
> +++ dump.h	Wed Jun  2 23:59:07 2004
11c11
<  #define DATELEN 40
---
>  #ifndef DUMPFREQ
diff -rN milter-greylist.orig/files/patch-spf.c milter-greylist/files/patch-spf.c
1,12d0
< --- spf.c.orig	Wed Apr 14 10:46:14 2004
< +++ spf.c	Thu Apr 29 15:19:01 2004
< @@ -45,8 +45,8 @@
<  #include <syslog.h>
<  #include <sys/types.h>
<  #include <sys/socket.h>
< -#include <arpa/inet.h>
<  #include <netinet/in.h>
< +#include <arpa/inet.h>
<  
<  #include "conf.h"
<  #include "spf.h"

--envbJBWh7q8WU6mo--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040603080257.GA21271>