[darcs-users] Re: Can I disable \xx quoting in record --interactive?

Tommy Pettersson ptp at lysator.liu.se
Sun Mar 20 20:35:33 UTC 2005

On Sun, Mar 20, 2005 at 10:45:51AM -0800, Junio C Hamano wrote:
> Yes I knew that was what you meant when you said "evil patches";

Ok, sorry for the misunderstanding.

> in the way.  Ideally they should use different hunk display
> routines.

But you will want to see your own patches even after recording
them, when you view the change log or push/pull them between
different branches.

> And even for the "apply" case, hex escaping is not always safer
> message change patches.  One of the patches you received from
> your i18n team looks like this:

If it was in Japanese it wouldn't matter how it looked,
I would still not be able to read it.  :-)

> You would probably need "show human readable without munging"
> even in the apply case as an option (it should not be the
> default in the apply case for safety).  Maybe the list of "what
> do you want to do with this hunk" choice can include "view it
> without hex munging"?

This is a terrific work-around until we get proper i18n,
I think.  There already is 'v' for view patch and 'x' for view
summary, so maybe 'z' or 'c' or 'b' could be view patch raw.
I think we should also be able to swap the default to raw
output in some way, with an environment variable or an option.

But still, it would be good if we could escape some control
characters even in raw mode, such as back space and especially

I found a description of EUC-JP and it looks like all multi
byte combinations use only bytes in the range 0x80-0xFF.  So it
would be easy to make something similar to DARCS_USE_ISPRINT,
maybe a DARCS_USE_8BIT.  But I also found some other encodings
that use multibytes in the range 0x20-0xFF, and all control
chars is below 0x20, so maybe we should just as well allow
everything in that range.  I'll think some more about it.

It _should_ not be this easy according to those who know what
they are doing, which I don't in this case.  I may very well
be opening up for big security problems.  Any help appreciated.

Tommy Pettersson <ptp at lysator.liu.se>

More information about the darcs-users mailing list