Return-Path: Delivered-To: apmail-harmony-commits-archive@www.apache.org Received: (qmail 28260 invoked from network); 15 Dec 2006 13:24:47 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 15 Dec 2006 13:24:47 -0000 Received: (qmail 97354 invoked by uid 500); 15 Dec 2006 13:24:54 -0000 Delivered-To: apmail-harmony-commits-archive@harmony.apache.org Received: (qmail 97329 invoked by uid 500); 15 Dec 2006 13:24:54 -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 97316 invoked by uid 99); 15 Dec 2006 13:24:54 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 15 Dec 2006 05:24:54 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= 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; Fri, 15 Dec 2006 05:24:46 -0800 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id F025C7140D2 for ; Fri, 15 Dec 2006 05:24:25 -0800 (PST) Message-ID: <16000108.1166189065981.JavaMail.jira@brutus> Date: Fri, 15 Dec 2006 05:24:25 -0800 (PST) From: "Alexei Zakharov (JIRA)" To: commits@harmony.apache.org Subject: [jira] Assigned: (HARMONY-2725) [classlib][sql] RI throws SerialException when both parameters in SerialBlob.getBytes(long pos, int len) are valid. In-Reply-To: <30090118.1166163261139.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ http://issues.apache.org/jira/browse/HARMONY-2725?page=all ] Alexei Zakharov reassigned HARMONY-2725: ---------------------------------------- Assignee: Alexei Zakharov > [classlib][sql] RI throws SerialException when both parameters in SerialBlob.getBytes(long pos, int len) are valid. > ------------------------------------------------------------------------------------------------------------------- > > Key: HARMONY-2725 > URL: http://issues.apache.org/jira/browse/HARMONY-2725 > Project: Harmony > Issue Type: Bug > Components: Non-bug differences from RI > Reporter: Andrew Zhang > Assigned To: Alexei Zakharov > Attachments: patch.diff > > > RI throws SerialException when both parameters in SerialBlob.getBytes(long pos, int len) are valid. > Consider following code: > public void testGetBytesJI1() throws Exception { > byte[] buf = { 1, 2, 3, 4, 5, 6, 7, 8 }; > SerialBlob serialBlob = new SerialBlob(buf); > byte [] data = serialBlob.getBytes(2, 1); > assertEquals(1, data.length); > assertEquals(2, data[0]); > } > Harmony passes the test, while RI throws SerialException with message "Invalid arguments: position cannot be less that 1". As discussed in mailing list, Harmony's behaviour is reasonable, and it's non bug different from RI. > Best regards, > Andrew -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira