From owner-freebsd-standards Thu Apr 25 19:22:43 2002 Delivered-To: freebsd-standards@freebsd.org Received: from rover.village.org (rover.bsdimp.com [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id E657637B41D; Thu, 25 Apr 2002 19:22:25 -0700 (PDT) Received: from harmony.village.org (harmony.village.org [10.0.0.6]) by rover.village.org (8.11.3/8.11.3) with ESMTP id g3Q2MNH93629; Thu, 25 Apr 2002 20:22:24 -0600 (MDT) (envelope-from imp@village.org) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.11.6/8.11.6) with ESMTP id g3Q2MMb44809; Thu, 25 Apr 2002 20:22:22 -0600 (MDT) (envelope-from imp@village.org) Date: Thu, 25 Apr 2002 20:22:17 -0600 (MDT) Message-Id: <20020425.202217.82927028.imp@village.org> To: mike@FreeBSD.ORG Cc: drosih@rpi.edu, arch@FreeBSD.ORG, freebsd-standards@FreeBSD.ORG Subject: Re: diff & patch problem with 'No newline' From: "M. Warner Losh" In-Reply-To: <20020425210035.A43192@espresso.q9media.com> References: <20020425210035.A43192@espresso.q9media.com> X-Mailer: Mew version 2.1 on Emacs 21.1 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-standards@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message: <20020425210035.A43192@espresso.q9media.com> Mike Barcroft writes: : Garance A Drosihn writes: : > And now, a mere two months later, I finally looked into it. : > Changing 'diff' is trivial, but the main issue is changing : > 'patch' to match. : > : > I found out that NetBSD had made changes to 'patch' so it : > does understand these lines. I copy&pasted those changes : > into our version, and it looks like it works right. The : > patch is pretty straightforward, and I would like to get : > it into our patch in for 4.6-release (along with the minor : > change to 'diff'). Any objections? : : Yes. I still maintain that files without a trailing new line are not : "text files", and should therefore be treated as binary files. Even : if we did consider these to be "text files", no standards that I'm : aware of define the behavior for this situation, so a non-standard : patch utility would be required to interpret these extensions. This : would make our generated diffs unportable in the same way as some of : the other vendors you mentioned as having this feature. There's lots of software (well, OK, subversion) that depends on the old, historical behavior. The historical behavior of diff has been to include the "this file doesn't end with a newline" message, not what FreeBSD hacked it to do. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-standards" in the body of the message