Add a patch to fdm to escape . in SMTP delivery as per RFC2821.

From nicm's repo, which is a better fix than my original diff.  OK nicm@
This commit is contained in:
sthen 2012-03-22 10:47:14 +00:00
parent c74130518f
commit d1c026b4c0
2 changed files with 23 additions and 5 deletions

View File

@ -1,13 +1,13 @@
# $OpenBSD: Makefile,v 1.14 2011/09/26 09:30:52 sthen Exp $
# $OpenBSD: Makefile,v 1.15 2012/03/22 10:47:14 sthen Exp $
COMMENT= fetch, filter and deliver mail
DISTNAME= fdm-1.6
REVISION = 2
REVISION= 3
CATEGORIES= mail
HOMEPAGE= http://fdm.sourceforge.net/
MAINTAINER= Nicholas Marriott <nicm@users.sourceforge.net>
HOMEPAGE= http://fdm.sourceforge.net/
MAINTAINER= Nicholas Marriott <nicm@users.sourceforge.net>
# BSD
PERMIT_PACKAGE_CDROM= Yes
@ -22,7 +22,6 @@ MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=fdm/}
LIB_DEPENDS += databases/tdb>=1.2.7
FAKE_FLAGS= PREFIX=${PREFIX}
USE_GROFF = Yes
post-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/fdm

View File

@ -0,0 +1,19 @@
$OpenBSD: patch-deliver-smtp_c,v 1.1 2012/03/22 10:47:14 sthen Exp $
From r1.58 upstream: properly escape . when delivering to SMTP.
--- deliver-smtp.c.orig Sun Dec 14 21:34:06 2008
+++ deliver-smtp.c Wed Mar 21 22:59:50 2012
@@ -160,8 +160,11 @@ deliver_smtp_deliver(struct deliver_ctx *dctx, struct
goto error;
line_init(m, &ptr, &len);
while (ptr != NULL) {
- if (len > 1)
+ if (len > 1) {
+ if (*ptr == '.')
+ io_write(io, ".", 1);
io_write(io, ptr, len - 1);
+ }
io_writeline(io, NULL);
/* Update if necessary. */