Stefan Küng wrote:
>[[[
>Compile time switch to use the Windows API's instead of apr_iconv to do
>the UTF-8 conversions.
>
>* subversion/libsvn_subr/utf.c
> (win_xlate_conv_buffer): New function, replacing apr_xlate_conv_buffer
> but using the Windows API instead of iconv.
> (get_xlate_handle_node): Instead of calling apr_xlate_open fill in the
> handle struct with Windows API information.
> (convert_to_stringbuf): Check if the source string has zero length
> before allocating memory.
> (convert_to_stringbuf): Call win_xlate_conv_buffer instead of
> apr_xlate_conv_buffer.
>]]]
>Index: subversion/libsvn_subr/utf.c
>===================================================================
>--- subversion/libsvn_subr/utf.c (Revision 16653)
>+++ subversion/libsvn_subr/utf.c (Arbeitskopie)
>@@ -125,6 +125,70 @@
> }
> }
>
>+#if defined(WIN32) && defined(NOICONV)
>+/* declare the struct here, so we can use its members */
>+struct apr_xlate_t {
>+ apr_pool_t *pool;
>+ char *frompage;
>+ char *topage;
>+ char *sbcs_table;
>+};
>
>
We can't redefine apr_xlate_t. You'll have to call it something else.
[...]
>+ requiredlen = MultiByteToWideChar(fromUTF8 ? CP_UTF8 : CP, 0, inbuf, -1, 0, 0);
>
>
IIRC CP_UTF8 is only supported on Win2k (maybe even WinXP) and later. So
the conversion will fail on older versions of Windows.
-- Brane
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Oct 12 19:28:54 2005