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

Re: "200 OK" error caused by non-ASCII characters?

From: Stefan Sperling <stsp_at_elego.de>
Date: Sun, 18 Oct 2009 22:02:55 +0200

On Sun, Oct 18, 2009 at 09:33:01PM +0200, Dag-Erling Smørgrav wrote:
> It so happens that the log message for revision 31 contains an ISO8859-1
> character.

Looks like it's something else:
$ svn propget --revprop -r31 svn:log http://svn.des.no/svn/openpam | file -
/dev/stdin: ASCII English text

> It is not the only such revision in the repo, but it is the
> first. In the other direction, a plain 'svn log' stops at revision 191,
> because the log message for revision 190 also contains ISO8859-1
> characters.
>
> Obiously, filtering a dump through iconv is not going to work, since the
> size of the log messages (and anything else that might contain non-ASCII
> characters) will change. I could write a script that fixed both the log
> messages and the lengths, but I'd rather not, unless there is no other
> solution.
>
> Any suggestions?

I'd just propedit the log messages using svn propedit:
  svn propedit --revprop -r31 svn:log http://svn.des.no/svn/openpam

If you need to script it you can use svn propget, iconv, and svn propset.
There is no need to dump/filter/load at all to fix log messages, it can
be done with an svn client.

Log messages in the repository should always be in UTF-8 but
unfortunately older servers didn't enforce this. As of 1.6.x the server
does enforce it.

I don't like way 'svn log' is behaving here BTW. Subversion should at
least print an error saying what is wrong with the log message instead
of bailing out after writing the first few opening tags of XML.

(By the way it's probably one of the darkest log message I've ever
seen :)

Stefan

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2408710

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-10-18 22:03:48 CEST

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.