Uploaded image for project: 'Pivot'
  1. Pivot
  2. PIVOT-989

StringSerializer does not use the correct Charset in "writeObject" method

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0.4, 2.1
    • Fix Version/s: 2.1, 2.0.5
    • Component/s: core-serialization
    • Labels:
      None
    • Environment:
      All

      Description

      In the StringSerializer.writeObject() method, the "getBytes()" call for the String is using the platform default charset instead of the given charset, resulting in possibly incorrect values (especially on Windows where the platform default is not UTF-8, which is the default for this class).

      There should be tests for this behavior in StringSerializerTest also.

        Activity

        Hide
        rwhitcomb Roger Whitcomb added a comment -

        Fixed in "trunk":
        Sending core\src\org\apache\pivot\serialization\StringSerializer.java
        Sending core\test\org\apache\pivot\serialization\test\StringSerializerTest.java
        Transmitting file data ..
        Committed revision 1747445.

        Merged and fixed in "branches/2.0.x":
        Sending .
        Sending core\src\org\apache\pivot\serialization\StringSerializer.java
        Sending core\test\org\apache\pivot\serialization\test\StringSerializerTest.java
        Transmitting file data ..
        Committed revision 1747449.

        Show
        rwhitcomb Roger Whitcomb added a comment - Fixed in "trunk": Sending core\src\org\apache\pivot\serialization\StringSerializer.java Sending core\test\org\apache\pivot\serialization\test\StringSerializerTest.java Transmitting file data .. Committed revision 1747445. Merged and fixed in "branches/2.0.x": Sending . Sending core\src\org\apache\pivot\serialization\StringSerializer.java Sending core\test\org\apache\pivot\serialization\test\StringSerializerTest.java Transmitting file data .. Committed revision 1747449.

          People

          • Assignee:
            rwhitcomb Roger Whitcomb
            Reporter:
            rwhitcomb Roger Whitcomb
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development