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

Re: TDiff with unicode files without BOM

From: Maurizio Ferraris Studio <mau_at_studioferraris.it>
Date: Sat, 20 Jul 2013 13:28:03 +0200

The problem arises only if the files come without BOM.
Files in UTF-16 with BOM are perfectly OK.

Unfortunately I have an application that produces files without BOM and
I need to put those in svn.

I attach four small files to demonstrate this issue.

File1BOM.txt is a normal UTF-16LE file with BOM
File1NoBOM.txt is the very same file without BOM
Same is for File2

If you start TortoiseMerge File1BOM File2BOM
everything looks ok, but if you use the other two
TortoiseMerge File1NoBOM File2NoBOM
you'll see the problem

Regards.
Mau.

On 19/07/2013 19.51, Stefan Küng wrote:
> On 19.07.2013 14:50, Maurizio Ferraris Studio wrote:
>> Hi all,
>> I have a file in a SVN repository that is unicode encoded, but misses
>> the BOM, the initial two bytes (FF FE) to make editors detect the
>> endianess of the file.
>> Using TDiff between versions resuts in strange behavior.
>> Characters are displayed with an interleaving blank like:
>> h e l l o
>> But the difference coloring is normally at the correct line but at half
>> the horizontal position, as if the position is somewhat counted
>> correctly in unicode-16 chars.
>> I can confirm that if the file do have the BOM the TDiff behavior is
>> correct.
>>
>> Since I have other diff tools that looks like they correctly interprets
>> the difference among versions, is this to be considered a possible bug?
>>
>> Do you have had similar experience?
>> Is it normal to have unicode-16 files without BOM?
>
> I guess with TDiff you mean TortoiseMerge?
>
> TortoiseMerge can handle utf-16 files just fine, we have a few of those
> in the TSVN repository as well.
>
> Can you maybe send two files with which you can reproduce this to either
> the mailing list or me directly?
>
> Stefan
>

-- 
_____________________________________________________________
Maurizio Ferraris                mailto:mau_at_studioferraris.it
Via Borgonuovo 27                http://www.studioferraris.it
10040 GIVOLETTO TO ITALY     pec: maurizio.ferraris_at_ingpec.eu
Public key: http://www.studioferraris.it/files/Maurizio.txt
------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3060908
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_tortoisesvn.tigris.org].




Received on 2013-07-20 13:29:48 CEST

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

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