bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #37577] NSString fails to persist/unpersists UTF-8 String correctly


From: Robin
Subject: [bug #37577] NSString fails to persist/unpersists UTF-8 String correctly
Date: Mon, 15 Oct 2012 13:29:34 +0000
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.24) Gecko/20111108 Fedora/3.6.24-1.fc14 Firefox/3.6.24

URL:
  <http://savannah.gnu.org/bugs/?37577>

                 Summary: NSString fails to persist/unpersists UTF-8 String
correctly
                 Project: GNUstep
            Submitted by: rdemet
            Submitted on: Mon 15 Oct 2012 01:29:33 PM GMT
                Category: Base/Foundation
                Severity: 3 - Normal
              Item Group: Bug
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any

    _______________________________________________________

Details:


When I encode an NSString  (using  encodeObject:value forKey:key) with any non
ASCII characters as UTF-8 (using NSString stringWithUTF8String), the persisted
string does not load back
with the same characters. Instead a much larger string is returned with
completely different data.

For instance the string : 
 "english -> γερμανικών δυνάμεων στον <-some Greek";

will load in as :
 攀渀最氀椀猀栀 ⴀ㸀 댃딃섃밃넃봃뤃먃츃봃 됃씃봃갃밃딃줃봃 쌃쐃뼃

This looks like a bug in either encoding or decoding of the NSString. However
I tried modifying the bom.m test in NSString and could not recreate the error
there, so perhaps it's in the encoding part.

I have not tried any other encodings.
Host: 64bit Linux
ICU version: ICU44
gnustep base: libgnustep-base.so.1.24.2





    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?37577>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]