Derby
  1. Derby
  2. DERBY-900

Remove use of String(byte[]) and String(byte[], int, int) constructors in network client leading to non-portable behaviour

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 10.1.1.0, 10.1.2.1, 10.1.3.1, 10.2.1.6
    • Fix Version/s: 10.1.3.1, 10.2.1.6
    • Component/s: Network Client
    • Labels:
      None
    • Issue & fix info:
      Patch Available

      Description

      These constructors use the Java default platform encoding to convert the bytes to a String, this typically leads to bugs on platforms with different encodings.

      Replace with code using fixed conversion, or alternative mechanisms.
      If the call is required its use should be commented as to why it is required.

      org.apache.derby.client.am.ClobOutputStream - some existing bug?
      org.apache.derby.client.am.DateTime - see DERBY-877
      org.apache.derby.client.am.sqlca

      I generated this list using the Java search in eclipse for references to the constructors
      String(byte[])
      String(byte[],int,int)

      1. testsecmec.zip
        64 kB
        Kathey Marsden
      2. derby900_p2_cleanup.diff.txt
        8 kB
        Sunitha Kambhampati
      3. derby900_p2_cleanup.stat.txt
        0.2 kB
        Sunitha Kambhampati
      4. derby900.p2_encodingChange.diff.txt
        4 kB
        Sunitha Kambhampati
      5. Derby900.p2.diff.txt
        8 kB
        Sunitha Kambhampati
      6. derby900.p2.stat.txt
        0.2 kB
        Sunitha Kambhampati
      7. derby900.test.stat.txt
        0.2 kB
        Sunitha Kambhampati
      8. derby900.test.diff.txt
        4 kB
        Sunitha Kambhampati
      9. TestEnc.java
        7 kB
        Sunitha Kambhampati
      10. for_10.1_derby900.diff.p1.txt
        1 kB
        Sunitha Kambhampati
      11. for_10.1_derby900.stat.p1.txt
        0.1 kB
        Sunitha Kambhampati
      12. derby900.diff.p1.txt
        2 kB
        Sunitha Kambhampati
      13. derby900.stat.p1.txt
        0.2 kB
        Sunitha Kambhampati

        Activity

          People

          • Assignee:
            Unassigned
            Reporter:
            Daniel John Debrunner
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development