db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Knut Anders Hatlen (JIRA)" <j...@apache.org>
Subject [jira] Updated: (DERBY-2935) DDMReader.readLengthAndCodePoint() decodes long integer incorrectly
Date Mon, 16 Jul 2007 08:46:04 GMT

     [ https://issues.apache.org/jira/browse/DERBY-2935?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel

Knut Anders Hatlen updated DERBY-2935:

    Attachment: test.diff

Attaching a test which uses 8 bytes for the length. The test passes both with and without
the fix. I'm only attaching it in case someone wants to experiment with it to find ways to
expose the bug.

> DDMReader.readLengthAndCodePoint() decodes long integer incorrectly
> -------------------------------------------------------------------
>                 Key: DERBY-2935
>                 URL: https://issues.apache.org/jira/browse/DERBY-2935
>             Project: Derby
>          Issue Type: Bug
>          Components: Network Server
>    Affects Versions:,,,
>            Reporter: Knut Anders Hatlen
>            Assignee: Knut Anders Hatlen
>            Priority: Minor
>         Attachments: decode-long.diff, test.diff
> DDMReader.readLengthAndCodePoint() contains code to decode a long integer from a byte
array. This code is broken since it uses int operations and not long operations in the decoding.
The long might be encoded using four, six or eight bytes, and since Derby currently always
uses the four bytes encoding, the bug is not exposed in the current code.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message