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

Re: svn command --cl don't support names that contain chinese characters.

From: Philip Martin <philip.martin_at_wandisco.com>
Date: Thu, 25 Apr 2013 13:31:40 +0100

"C. Michael Pilato" <cmpilato_at_collab.net> writes:

> Your Linux box is probably using a UTF8 locale, Philip. Perhaps the OP's
> Windows box is using something else (GB18030 or somesuch)?
>
> Is this all that's needed?
>
> Index: subversion/svn/svn.c
> ===================================================================
> --- subversion/svn/svn.c (revision 1471390)
> +++ subversion/svn/svn.c (working copy)
> @@ -2159,7 +2159,8 @@
> opt_state.remove = TRUE;
> break;
> case opt_changelist:
> - opt_state.changelist = apr_pstrdup(pool, opt_arg);
> + SVN_INT_ERR(svn_utf_cstring_to_utf8(&utf8_opt_arg, opt_arg, pool));
> + opt_state.changelist = utf8_opt_arg;
> if (opt_state.changelist[0] == '\0')
> {
> err = svn_error_create(SVN_ERR_CL_ARG_PARSING_ERROR, NULL,

Yes, I was using UTF-8. I see the bug in iso-8859-1:

$ svn cl å wc/f
A [å] wc/f
$ svn st wc

--- Changelist 'å':
        wc/f
$ svn st --cl å wc
$

With your patch:

$ svn st --cl å wc

--- Changelist 'å':
        wc/f

-- 
Certified & Supported Apache Subversion Downloads:
http://www.wandisco.com/subversion/download
Received on 2013-04-25 14:32:36 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.