From owner-freebsd-bugs@FreeBSD.ORG Tue Feb 2 14:20:03 2010 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 503991065672 for ; Tue, 2 Feb 2010 14:20:03 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 3F52C8FC1A for ; Tue, 2 Feb 2010 14:20:03 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id o12EK2j8059139 for ; Tue, 2 Feb 2010 14:20:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id o12EK2pe059138; Tue, 2 Feb 2010 14:20:02 GMT (envelope-from gnats) Date: Tue, 2 Feb 2010 14:20:02 GMT Message-Id: <201002021420.o12EK2pe059138@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Pete French Cc: Subject: Re: bin/131861: mail(1) misses addresses when replying to all X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Pete French List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Feb 2010 14:20:03 -0000 The following reply was made to PR bin/131861; it has been noted by GNATS. From: Pete French To: bug-followup@FreeBSD.org, petefrench@ticketswitch.com Cc: Subject: Re: bin/131861: mail(1) misses addresses when replying to all Date: Tue, 02 Feb 2010 14:19:34 +0000 The following patch (to util.c, not aux.c - that was an error!) appears to fix this. It allows a comma to be followed directly by a quotation mark as well as a space. The space skipping code needs a minor adaptation to allow it to work when the current character is not a space, hence the second change. --- usr.bin/mail/util.c.orig 2010-02-02 14:10:34.220987358 +0000 +++ usr.bin/mail/util.c 2010-02-02 14:12:49.968147827 +0000 @@ -496,10 +496,10 @@ *cp2++ = ' '; } *cp2++ = c; - if (c == ',' && *cp == ' ' && !gotlt) { + if (c == ',' && (*cp == ' ' || *cp == '"') && !gotlt) { *cp2++ = ' '; - while (*++cp == ' ') - ; + while (*cp == ' ') + cp++; lastsp = 0; bufend = cp2; }