d1c026b4c0
From nicm's repo, which is a better fix than my original diff. OK nicm@
20 lines
571 B
Plaintext
20 lines
571 B
Plaintext
$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. */
|