Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 57556 invoked from network); 20 Jan 2010 12:21:18 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 20 Jan 2010 12:21:18 -0000 Received: (qmail 49816 invoked by uid 500); 20 Jan 2010 12:21:18 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 49762 invoked by uid 500); 20 Jan 2010 12:21:18 -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 49754 invoked by uid 99); 20 Jan 2010 12:21:18 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 20 Jan 2010 12:21:18 +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, 20 Jan 2010 12:21:16 +0000 Received: from brutus.apache.org (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 804FD234C1E9 for ; Wed, 20 Jan 2010 04:20:54 -0800 (PST) Message-ID: <882209214.367961263990054524.JavaMail.jira@brutus.apache.org> Date: Wed, 20 Jan 2010 12:20:54 +0000 (UTC) From: "Knut Anders Hatlen (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Commented: (DERBY-4519) Infinite loop in StreamFileContainer.writeColumn In-Reply-To: <1087987879.338941263913985614.JavaMail.jira@brutus.apache.org> 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/DERBY-4519?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12802807#action_12802807 ] Knut Anders Hatlen commented on DERBY-4519: ------------------------------------------- Thanks, Kristian. The patch looks good. +1 > Infinite loop in StreamFileContainer.writeColumn > ------------------------------------------------ > > Key: DERBY-4519 > URL: https://issues.apache.org/jira/browse/DERBY-4519 > Project: Derby > Issue Type: Bug > Components: Store > Affects Versions: 10.0.2.1, 10.1.3.1, 10.2.2.0, 10.3.3.0, 10.4.2.0, 10.5.3.0, 10.6.0.0 > Reporter: Kristian Waagan > Assignee: Kristian Waagan > Fix For: 10.6.0.0 > > Attachments: derby-4519-1a-argument_swap.diff, derby-4519-2a-infinite_loop_fixes.diff > > > The offset and length argument have been swapped in the calls to InputStream.read(byte,offset, length) and write(byte,offset, length). This code is inside a do-while (true) loop, and the only normal way out is when InputStream.read returns -1. This will never happen since the stream is asked to read zero bytes. Derby ends up eating up all available CPU, limited to a single core / CPU. > The bug hasn't been observed because Derby is materializing all values when calling this code. Enabling streaming capabilities in the sorter revealed it. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.