You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2015/04/02 11:41:54 UTC

[jira] [Commented] (AVRO-1593) C++ json encoder assumes "C" locale and generates invalid UTF-8 sequence

    [ https://issues.apache.org/jira/browse/AVRO-1593?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14392454#comment-14392454 ] 

ASF GitHub Bot commented on AVRO-1593:
--------------------------------------

GitHub user hatemhelal opened a pull request:

    https://github.com/apache/avro/pull/32

    AVRO-1593. Use classic locale to escape control chars

    See https://issues.apache.org/jira/browse/AVRO-1593

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/hatemhelal/avro patch-1

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/avro/pull/32.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #32
    
----
commit 3c87e7cbf2a8f03c570ec763b7d92da80bc86326
Author: hatemhelal <ha...@gmail.com>
Date:   2015-04-02T09:41:12Z

    AVRO-1593. Use classic locale to escape control chars
    
    See https://issues.apache.org/jira/browse/AVRO-1593

----


> C++ json encoder assumes "C" locale and generates invalid UTF-8 sequence 
> -------------------------------------------------------------------------
>
>                 Key: AVRO-1593
>                 URL: https://issues.apache.org/jira/browse/AVRO-1593
>             Project: Avro
>          Issue Type: Bug
>          Components: c++
>    Affects Versions: 1.7.7
>         Environment: windows-1252 encoding
>            Reporter: Hatem Helal
>            Priority: Critical
>             Fix For: 1.7.8
>
>
> encoding a multibyte UTF-8 code point such as:
> "\xEF\xBD\x81"
> Incorrectly becomes:
> "\xEF\xBD\U0081"
> When encoded in the service running in the windows-1252 locale.  This isnĀ¹t a valid UTF-8 sequence so we end up with Mojibake when reading back the JSON encoded string.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)