harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tim Ellison (JIRA)" <j...@apache.org>
Subject [jira] Resolved: (HARMONY-6134) [classlib][luni] java.io.BufferedInputStream.reset() throws IOException after skipping the marked position
Date Wed, 06 May 2009 13:53:30 GMT

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

Tim Ellison resolved HARMONY-6134.
----------------------------------

       Resolution: Fixed
    Fix Version/s:     (was: 5.0M9)
                   5.0M10

Thanks Kevin.

Patch applied to LUNI module at repo revision r772257.

Please verify it was applied as you expected.


> [classlib][luni] java.io.BufferedInputStream.reset() throws IOException after skipping
the marked position
> ----------------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-6134
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6134
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M8
>            Reporter: Kevin Zhou
>            Assignee: Tim Ellison
>             Fix For: 5.0M10
>
>         Attachments: HARMONY-6134.diff
>
>
> Given a test case [1], HY throws IOException after skipping the marked position while
RI doesn't.
> If SKIP_VALUE<=5, HY and RI pass the test; 
> else HY throws java.lang.IOException [2] but RI also passes this.
> [1] Test Case:
> public void test_skipJ_scenario1() throws IOException {
>     byte[] input = "12345678900".getBytes();
>     BufferedInputStream buffis = new BufferedInputStream(
>         new ByteArrayInputStream(input));
>     buffis.read();
>     buffis.mark(5);
>     buffis.skip(SKIP_VALUE);
>     buffis.reset();
> }
> public void test_skipJ_scenario2() throws IOException {
>     byte[] input = "12345678900".getBytes();
>     BufferedInputStream buffis = new BufferedInputStream(
>         new ByteArrayInputStream(input));
>     buffis.mark(5);
>     buffis.skip(SKIP_VALUE + 1);
>     buffis.reset();
> }
> [2] Stack Trace:
> java.io.IOException: Mark has been invalidated.
> at java.io.BufferedInputStream.reset(BufferedInputStream.java:351)

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


Mime
View raw message