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

JavaHL blame callback and encoding

From: Conor MacNeill <conor_at_cenqua.com>
Date: 2005-09-07 04:39:53 CEST

Hi,

I think there is a problem with the BlameCallback interface in the
current JavaHL implementation.

The callback method is defined as:

public void singleLine(java.util.Date changed,
                       long revision,
                       java.lang.String author,
                       java.lang.String line)

The problem is that, to create that line as a String instance, JavaHL
has assumed the encoding of the file content. In particular it uses the
JNI utility function env->NewStringUTF(txt) to create the line,
effectively assuming UTF-8 encoding.

Probably the interface should actually pass a byte[] for the line
content and let the client apply the encoding it wishes to use.

Cheers
Conor

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Sep 7 04:40:36 2005

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