Subject: Re: bug#17522: diff-mode frustrates attempt to correct corrupted diff file.

From: Alan Mackenzie <[email-masked]>
Date: Fri, 23 May 2014 20:43:11 +0000

Hi, Stefan.

On Thu, May 22, 2014 at 10:07:17PM -0400, Stefan Monnier wrote:
> > So why can't we have a `y-or-n-p' or a `message' when diff-mode is about
> > to change a hunk header, possibly fouling it up?

> Because we don't agree on UI issues.

Pardon?  What has our alleged disagreement about some UI issues (which
ones, by the way?) got to do with solving this bug?

To restore some context, what happened was that whilst editing a patch
file (which had become corrupted by email software) in Diff Mode, Diff
Mode, without seeking permission from or even informing the user,
corrupted a hunk header by writing 0 into the "number of lines" fields,
thus leaving the patch file unusable.

Do you think it is possible to amend the hunk header editing routine so
that it can't make such mistakes?  I'm sceptical.

Just to emphasise once more, it was the surreptitious nature of Diff
Mode's corruption that caused the pain.  If it had been open about its
changes, it would have been so much easier to reverse them.

Do you have a better proposal for a fix to this bug than my proposal?

>         Stefan

-- 
Alan Mackenzie (Nuremberg, Germany).