git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* GNU patch close to next stable release (2)
@ 2012-08-01 11:50 Andreas Grünbacher
  2012-08-01 17:58 ` Junio C Hamano
  0 siblings, 1 reply; 5+ messages in thread
From: Andreas Grünbacher @ 2012-08-01 11:50 UTC (permalink / raw)
  To: bug-patch; +Cc: git

After another improvement in git-style diff support to better handle
concatenated
diffs, here is a last call for testing to ensure that the code works
well enough to
become the next stable release. Please find the latest development snapshots
here:

  ftp://alpha.gnu.org/gnu/patch/

The following significant changes have happened since the last stable release
in December 2009:

* Support for most features of the "diff --git" format, including renames and
  copies, permission changes, and symlink diffs.  Binary diffs are not
  supported yet; patch will complain and skip them.

* Support for double-quoted filenames in the "diff --git" format: when a
  filename starts with a double quote, it is interpreted as a C string
  literal.  The escape sequences \\, \", \a, \b, \f, \n, \r, \t, \v, and \ooo
  (a three-digit octal number between 0 and 255) are recognized.

* Patch now ignores destination file names that are absolute or that contain
  a component of "..".  This addresses CVE-2010-4651.

* Refuse to apply a normal patch to a symlink.  (Previous versions of patch
  were replacing the symlink with a regular file.)

* When trying to modify a read-only file, warn about the potential problem
  by default.  The --read-only command line option allows to change this
  behavior.

* Files that should be deleted are now deleted once the entire patch file has
  been read.  This fixes a bug with numbered backup files.

* When a timestamp specifies a time zone, honor that instead of assuming the
  local time zone (--set-date) or Universal Coordinated Time (--set-utc).

* Support for nanosecond precision timestamps.

* Many portability and bug fixes.

Please report bugs or suggestions on the <bug-patch@gnu.org> mailing list, or
in the project's bug tracker on Savannah:

  http://savannah.gnu.org/projects/patch

Thanks,
Andreas

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: GNU patch close to next stable release (2)
  2012-08-01 11:50 GNU patch close to next stable release (2) Andreas Grünbacher
@ 2012-08-01 17:58 ` Junio C Hamano
  2012-08-02 20:02   ` Andreas Grünbacher
  0 siblings, 1 reply; 5+ messages in thread
From: Junio C Hamano @ 2012-08-01 17:58 UTC (permalink / raw)
  To: Andreas Grünbacher; +Cc: bug-patch, git

Andreas Grünbacher <agruen@gnu.org> writes:

> * Support for double-quoted filenames in the "diff --git" format: when a
>   filename starts with a double quote, it is interpreted as a C string
>   literal.  The escape sequences \\, \", \a, \b, \f, \n, \r, \t, \v, and \ooo
>   (a three-digit octal number between 0 and 255) are recognized.

Is this also available in non-git diffs?  IIRC, this extension to
allow funny characters in pathnames was proposed by and discussed
with Paul Eggert (listed as one of GNU diffutils maintainers at
www.gnu.org/software/diffutils/) and git happened to adopt it
earlier than "GNU diff" itself did.

I found it a bit odd to see this listed as one of the items needed
to support "diff --git" oddity.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: GNU patch close to next stable release (2)
  2012-08-01 17:58 ` Junio C Hamano
@ 2012-08-02 20:02   ` Andreas Grünbacher
       [not found]     ` <CAHpGcML5PVAgd9x75=5k1-ev+Px4V+26KJhhyZk-O54p0WxfxQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 5+ messages in thread
From: Andreas Grünbacher @ 2012-08-02 20:02 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: bug-patch, git, bug-diffutils, Paul Eggert, Jim Meyering

Junio,

2012/8/1 Junio C Hamano <gitster@pobox.com>:
> Andreas Grünbacher <agruen@gnu.org> writes:
>
>> * Support for double-quoted filenames in the "diff --git" format: when a
>>   filename starts with a double quote, it is interpreted as a C string
>>   literal.  The escape sequences \\, \", \a, \b, \f, \n, \r, \t, \v, and \ooo
>>   (a three-digit octal number between 0 and 255) are recognized.
>
> Is this also available in non-git diffs?

I have only enabled this for git-style diffs for now. GNU diff doesn't do
filename quoting so far and if it eventually implements a slightly different
form of quoting (which I wouldn't recommend), we might be in trouble.

> IIRC, this extension to allow funny characters in pathnames was
> proposed by and discussed with Paul Eggert (listed as one of GNU
> diffutils maintainers at www.gnu.org/software/diffutils/) and git happened
> to adopt it earlier than "GNU diff" itself did.

Paul and Jim, any thoughts about adding filename quoting to GNU diff anytime
soon, or about the format?

Thanks,
Andreas

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: GNU patch close to next stable release (2)
       [not found]     ` <CAHpGcML5PVAgd9x75=5k1-ev+Px4V+26KJhhyZk-O54p0WxfxQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2012-08-02 21:08       ` Paul Eggert
       [not found]         ` <501AEC59.7010907-764C0pRuGfqVc3sceRu5cw@public.gmane.org>
  0 siblings, 1 reply; 5+ messages in thread
From: Paul Eggert @ 2012-08-02 21:08 UTC (permalink / raw)
  To: Andreas Grünbacher
  Cc: bug-diffutils-mXXj517/zsQ, Jim Meyering, bug-patch-mXXj517/zsQ,
	git-u79uwXL29TY76Z2rM5mHXA, Junio C Hamano

On 08/02/2012 01:02 PM, Andreas Grünbacher wrote:
> Paul and Jim, any thoughts about adding filename quoting to GNU diff anytime
> soon, or about the format?

The git format looks OK.  I don't have time right now to add it to GNU diff, tho.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: GNU patch close to next stable release (2)
       [not found]         ` <501AEC59.7010907-764C0pRuGfqVc3sceRu5cw@public.gmane.org>
@ 2012-08-02 21:13           ` Jim Meyering
  0 siblings, 0 replies; 5+ messages in thread
From: Jim Meyering @ 2012-08-02 21:13 UTC (permalink / raw)
  To: Paul Eggert
  Cc: bug-diffutils-mXXj517/zsQ, Andreas Grünbacher,
	Junio C Hamano, bug-patch-mXXj517/zsQ, git-u79uwXL29TY76Z2rM5mHXA

Paul Eggert wrote:
> On 08/02/2012 01:02 PM, Andreas Grünbacher wrote:
>> Paul and Jim, any thoughts about adding filename quoting to GNU diff anytime
>> soon, or about the format?
>
> The git format looks OK.  I don't have time right now to add it to GNU diff, tho.

I agree, and have no more free time for the task than Paul does.
Would someone care to contribute a complete patch?

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-08-02 21:13 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-01 11:50 GNU patch close to next stable release (2) Andreas Grünbacher
2012-08-01 17:58 ` Junio C Hamano
2012-08-02 20:02   ` Andreas Grünbacher
     [not found]     ` <CAHpGcML5PVAgd9x75=5k1-ev+Px4V+26KJhhyZk-O54p0WxfxQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-08-02 21:08       ` Paul Eggert
     [not found]         ` <501AEC59.7010907-764C0pRuGfqVc3sceRu5cw@public.gmane.org>
2012-08-02 21:13           ` Jim Meyering

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).