From owner-svn-src-all@FreeBSD.ORG Thu May 27 12:59:49 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 75FDA1065674; Thu, 27 May 2010 12:59:49 +0000 (UTC) (envelope-from uqs@FreeBSD.org) Received: from svn.freebsd.org (unknown [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 653758FC21; Thu, 27 May 2010 12:59:49 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o4RCxnZr077881; Thu, 27 May 2010 12:59:49 GMT (envelope-from uqs@svn.freebsd.org) Received: (from uqs@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o4RCxn2O077879; Thu, 27 May 2010 12:59:49 GMT (envelope-from uqs@svn.freebsd.org) Message-Id: <201005271259.o4RCxn2O077879@svn.freebsd.org> From: Ulrich Spoerlein Date: Thu, 27 May 2010 12:59:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r208592 - head/usr.bin/mail X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 May 2010 12:59:49 -0000 Author: uqs Date: Thu May 27 12:59:49 2010 New Revision: 208592 URL: http://svn.freebsd.org/changeset/base/208592 Log: mail(1) misses addresses when replying to all There's a parsing error for fields where addresses are not separated by space. This is often produced by MS Outlook, eg.: Cc: ,"Mr Foo" The following line now splits into the right tokens: Cc: f@b.com,z@y.de, ,, "foo" ,"bar" PR: bin/131861 Submitted by: Pete French Tested by: Pete French Reviewed by: mikeh MFC after: 2 weeks Modified: head/usr.bin/mail/util.c Modified: head/usr.bin/mail/util.c ============================================================================== --- head/usr.bin/mail/util.c Thu May 27 12:54:42 2010 (r208591) +++ head/usr.bin/mail/util.c Thu May 27 12:59:49 2010 (r208592) @@ -496,10 +496,11 @@ skin(name) *cp2++ = ' '; } *cp2++ = c; - if (c == ',' && *cp == ' ' && !gotlt) { + if (c == ',' && !gotlt && + (*cp == ' ' || *cp == '"' || *cp == '<')) { *cp2++ = ' '; - while (*++cp == ' ') - ; + while (*cp == ' ') + cp++; lastsp = 0; bufend = cp2; }