From derby-dev-return-49718-apmail-db-derby-dev-archive=db.apache.org@db.apache.org Mon Oct 15 11:26:42 2007 Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 30192 invoked from network); 15 Oct 2007 11:26:42 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 15 Oct 2007 11:26:42 -0000 Received: (qmail 41370 invoked by uid 500); 15 Oct 2007 11:26:29 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 41333 invoked by uid 500); 15 Oct 2007 11:26:29 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 41324 invoked by uid 99); 15 Oct 2007 11:26:29 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Oct 2007 04:26:29 -0700 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Oct 2007 11:26:41 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 008FE71422E for ; Mon, 15 Oct 2007 04:25:51 -0700 (PDT) Message-ID: <2736005.1192447550999.JavaMail.jira@brutus> Date: Mon, 15 Oct 2007 04:25:50 -0700 (PDT) From: =?utf-8?Q?J=C3=B8rgen_L=C3=B8land_=28JIRA=29?= To: derby-dev@db.apache.org Subject: [jira] Updated: (DERBY-3003) ArrayInputStream.skipBytes() may throw EOFException which is disallowed by java.io.DataInput In-Reply-To: <26107854.1186998343672.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-3003?page=3Dcom.atlassia= n.jira.plugin.system.issuetabpanels:all-tabpanel ] J=C3=B8rgen L=C3=B8land updated DERBY-3003: --------------------------------- Attachment: derby-3003-1.diff derby-3003-1.stat Attached a very simple fix for this issue. All tests pass. > ArrayInputStream.skipBytes() may throw EOFException which is disallowed b= y java.io.DataInput > -------------------------------------------------------------------------= ------------------- > > Key: DERBY-3003 > URL: https://issues.apache.org/jira/browse/DERBY-3003 > Project: Derby > Issue Type: Bug > Components: Services > Affects Versions: 10.4.0.0 > Reporter: Knut Anders Hatlen > Assignee: J=C3=B8rgen L=C3=B8land > Priority: Minor > Attachments: derby-3003-1.diff, derby-3003-1.stat > > > The javadoc for java.io.DataInput.skipBytes(int) says (): > > This method never throws an EOFException. > The implementation of this method in org.apache.derby.iapi.services.io.Ar= rayInputStream says: > =09=09if ((position + n) > end) { > =09=09=09throw new EOFException(); > =09=09} > The method in ArrayInputStream should be changed so that it skips as many= bytes as possible (max n) and returns the actual number of bytes skipped, = even when EOF is reached. --=20 This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.