[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

RE: Bug patching Unicode files

From: Hugo González <h.gonzalez_at_ingeciber.com>
Date: Fri, 25 Nov 2016 13:38:02 +0100

Apart from that, I tried to fix the diff file myself, just to check if the
error was only during the generation of the diff file or also to apply an
Unicode diff file. I edited the “changes.diff” file using Notepad++ and
removed the “\0” codes, so I had an ANSI diff file called
“changes_fixed.diff” that also fails in the same way to apply the patch. I
also converted the ANSI diff file into an Unicode UCS2-LittleEndian file
with Notepad++, and now Subversion cannot apply the patch… So, it seems
there could be three bugs there: one in the creation of diff files, another
one applying ANSI diff files to Unicode files, and another just working with
Unicode diff files. I attach all the examples again, with the manually fixed
diff files. Best regards,

 

Hugo González

 

 

De: Hugo González [mailto:h.gonzalez_at_ingeciber.com]
Enviado el: viernes, 25 de noviembre de 2016 12:36
Para: 'users_at_subversion.apache.org'
Asunto: Bug patching Unicode files

 

Hello, and congratulations for your great job at the Subversion project. I
think it is an amazing tool.

I have found a bug when trying to apply a patch over a Unicode file. The
steps to reproduce this bug are:

 

1. Create and version a Unicode file in your repository, for example:
MyFavouriteChineseSentences.txt

2. Modify that Unicode file.

3. Create a patch with your modifications (svn diff > changes.diff)

4. Revert the modifications of the file.

5. Apply the patch to modify the file again (svn patch changes.diff)

6. You get a corrupted file and the modifications are lost.

 

It seems the diff file is malformed, resulting in a corrupted patched file.
I attach the documents of my example.

I hope you can fix this, because I work with a lot of Unicode files, but I
understand this could be difficult because of command line limitations…

Any feedback or advice will be welcome. Thank you very much in advance,

 

Hugo González

____________________________________________________________________________
___________________________________

Hugo González
h.gonzalez_at_ingeciber.com
Tlf: +34 91 386 22 22
Fax: +34 91 386 45 80

Ingeciber S.A.
Avda. Monforte de Lemos, 189 - 28035 - Madrid - España
info_at_ingeciber.com
www.ingeciber.com | www.civilfem.com

Este mensaje se dirige exclusivamente a su destinatario y puede contener
información privilegiada o confidencial. Si no es vd. el destinatario
indicado, queda notificado de que la utilización, divulgación y/o copia sin
autorización está prohibida en virtud de la legislación vigente. Si ha
recibido este mensaje por error, le rogamos que nos lo comunique
inmediatamente por esta misma vía y proceda a su destrucción.
This message is intended exclusively for its addressee and may contain
information that is CONFIDENTIAL and protected by professional privilege.If
you are not the intended recipient you are hereby notified that any
dissemination, copy or disclosure of this communication is strictly
prohibited by law. If this message has been received in error, please
immediately notify us via e-mail and delete it.

 

 

Received on 2016-11-25 13:36:39 CET

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.