summaryrefslogtreecommitdiff
path: root/mail/mini_sendmail/patches
diff options
context:
space:
mode:
authormartin <martin>2006-12-01 10:40:48 +0000
committermartin <martin>2006-12-01 10:40:48 +0000
commite360e90b263f973fc8d3d74b332d27f6bf0aa27b (patch)
tree8620fd5d9c26c9f87d4d5837853d66c5dbfe8d90 /mail/mini_sendmail/patches
parentf96140da6335e6d41e8b70ea6efa341387c002ec (diff)
downloadpkgsrc-e360e90b263f973fc8d3d74b332d27f6bf0aa27b.tar.gz
Fix an off by one error in the address parser, introduced by our patch.
Found by Ond?ej T?ma (sorry for the missing chars) and analyzed by Lasse Hillerøe Petersen.
Diffstat (limited to 'mail/mini_sendmail/patches')
-rw-r--r--mail/mini_sendmail/patches/patch-aa13
1 files changed, 5 insertions, 8 deletions
diff --git a/mail/mini_sendmail/patches/patch-aa b/mail/mini_sendmail/patches/patch-aa
index f8d80f13519..dfd3bd6461c 100644
--- a/mail/mini_sendmail/patches/patch-aa
+++ b/mail/mini_sendmail/patches/patch-aa
@@ -1,7 +1,7 @@
-$NetBSD: patch-aa,v 1.8 2006/06/15 20:52:05 martin Exp $
+$NetBSD: patch-aa,v 1.9 2006/12/01 10:40:48 martin Exp $
--- mini_sendmail.c.orig 2005-06-29 19:37:15.000000000 +0200
-+++ mini_sendmail.c 2006-06-15 22:42:04.000000000 +0200
++++ mini_sendmail.c 2006-12-01 11:35:27.000000000 +0100
@@ -66,8 +66,13 @@ static char* argv0;
static char* fake_from;
static int parse_message, verbose;
@@ -123,7 +123,7 @@ $NetBSD: patch-aa,v 1.8 2006/06/15 20:52:05 martin Exp $
}
break;
case ',':
-@@ -532,25 +568,46 @@ static void
+@@ -532,25 +568,43 @@ static void
add_recipient( char* recipient, int len )
{
char buf[1000];
@@ -163,9 +163,6 @@ $NetBSD: patch-aa,v 1.8 2006/06/15 20:52:05 martin Exp $
+ while (len > 2 && recipient[--len] != '>')
+ ; /* nothing */
+
-+ if (recipient[len] == '>')
-+ --len;
-+
+ }
(void) snprintf( buf, sizeof(buf), "RCPT TO:<%.*s>", len, recipient );
@@ -177,7 +174,7 @@ $NetBSD: patch-aa,v 1.8 2006/06/15 20:52:05 martin Exp $
send_command( buf );
status = read_response();
if ( status != 250 && status != 251 )
-@@ -569,7 +626,7 @@ add_recipient( char* recipient, int len
+@@ -569,7 +623,7 @@ add_recipient( char* recipient, int len
#endif
static int
@@ -186,7 +183,7 @@ $NetBSD: patch-aa,v 1.8 2006/06/15 20:52:05 martin Exp $
{
#ifdef USE_IPV6
struct sockaddr_in6 sa;
-@@ -744,10 +801,10 @@ open_client_socket( void )
+@@ -744,10 +798,10 @@ open_client_socket( void )
sockfd = socket( sock_family, sock_type, sock_protocol );
if ( sockfd < 0 )