Return-Path: Delivered-To: apmail-harmony-commits-archive@www.apache.org Received: (qmail 90883 invoked from network); 6 May 2009 12:54:53 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 6 May 2009 12:54:53 -0000 Received: (qmail 19235 invoked by uid 500); 6 May 2009 12:54:53 -0000 Delivered-To: apmail-harmony-commits-archive@harmony.apache.org Received: (qmail 19198 invoked by uid 500); 6 May 2009 12:54:53 -0000 Mailing-List: contact commits-help@harmony.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@harmony.apache.org Delivered-To: mailing list commits@harmony.apache.org Received: (qmail 19159 invoked by uid 99); 6 May 2009 12:54:53 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 06 May 2009 12:54:53 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 06 May 2009 12:54:51 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id A14AC234C04B for ; Wed, 6 May 2009 05:54:31 -0700 (PDT) Message-ID: <1527521038.1241614471659.JavaMail.jira@brutus> Date: Wed, 6 May 2009 05:54:31 -0700 (PDT) From: "Tim Ellison (JIRA)" To: commits@harmony.apache.org Subject: [jira] Resolved: (HARMONY-6133) [classlib][luni] java.io.BufferedInputStream.skip(0) shouldn't throw IOException In-Reply-To: <1054262218.1238122490544.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HARMONY-6133?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Tim Ellison resolved HARMONY-6133. ---------------------------------- Resolution: Fixed Fix Version/s: (was: 5.0M9) 5.0M10 Thanks Kevin. Patch applied to LUNI module at repo revision r772188. Please verify. > [classlib][luni] java.io.BufferedInputStream.skip(0) shouldn't throw IOException > -------------------------------------------------------------------------------- > > Key: HARMONY-6133 > URL: https://issues.apache.org/jira/browse/HARMONY-6133 > Project: Harmony > Issue Type: Bug > Components: Classlib > Affects Versions: 5.0M8 > Reporter: Kevin Zhou > Assignee: Tim Ellison > Fix For: 5.0M10 > > Attachments: HARMONY-6133.diff > > > Given a test case [1], HY throws a java.lang.IOException [2], while RI passes this test. > Create a BufferedInputStream object using a null InputStream, java.io.BufferedInputStream.skip(0) should not throw IOException. > While at this case, java.io.BufferedInputStream.skip(Value > 0) should throw IOException. > [1] Test Case : > public void test_skip_scenario1() throws IOException { > BufferedInputStream buf = new BufferedInputStream(null, 5); > assertEquals(0, buf.skip(0)); > } > public void test_skip_scenario2() throws IOException { > BufferedInputStream buf = new BufferedInputStream(null, 5); > try { > buf.skip(1); > fail("should throw IOException"); > } catch (IOException e) { > // Expected > } > } > [2] Stack Trace: > java.io.IOException: Stream is closed > at java.io.BufferedInputStream.skip(BufferedInputStream.java:346) -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.