Return-Path: Delivered-To: apmail-db-ojb-dev-archive@www.apache.org Received: (qmail 49005 invoked from network); 23 Jun 2006 21:25:56 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 23 Jun 2006 21:25:56 -0000 Received: (qmail 90023 invoked by uid 500); 23 Jun 2006 21:25:55 -0000 Delivered-To: apmail-db-ojb-dev-archive@db.apache.org Received: (qmail 89866 invoked by uid 500); 23 Jun 2006 21:25:55 -0000 Mailing-List: contact ojb-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "OJB Developers List" Reply-To: "OJB Developers List" Delivered-To: mailing list ojb-dev@db.apache.org Received: (qmail 89844 invoked by uid 500); 23 Jun 2006 21:25:54 -0000 Received: (qmail 89840 invoked by uid 99); 23 Jun 2006 21:25:54 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 Jun 2006 14:25:54 -0700 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [140.211.166.113] (HELO eris.apache.org) (140.211.166.113) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 Jun 2006 14:25:54 -0700 Received: by eris.apache.org (Postfix, from userid 65534) id 37EBF1A983A; Fri, 23 Jun 2006 14:25:34 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r416821 - /db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/util/IdentityArrayList.java Date: Fri, 23 Jun 2006 21:25:33 -0000 To: ojb-commits@db.apache.org From: arminw@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20060623212534.37EBF1A983A@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Author: arminw Date: Fri Jun 23 14:25:33 2006 New Revision: 416821 URL: http://svn.apache.org/viewvc?rev=416821&view=rev Log: code cleanup Modified: db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/util/IdentityArrayList.java Modified: db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/util/IdentityArrayList.java URL: http://svn.apache.org/viewvc/db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/util/IdentityArrayList.java?rev=416821&r1=416820&r2=416821&view=diff ============================================================================== --- db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/util/IdentityArrayList.java (original) +++ db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/util/IdentityArrayList.java Fri Jun 23 14:25:33 2006 @@ -66,26 +66,12 @@ public boolean remove(Object o) { Iterator e = iterator(); - if(o == null) + while(e.hasNext()) { - while(e.hasNext()) + if(o == e.next()) { - if(e.next() == null) - { - e.remove(); - return true; - } - } - } - else - { - while(e.hasNext()) - { - if(o == e.next()) - { - e.remove(); - return true; - } + e.remove(); + return true; } } return false; --------------------------------------------------------------------- To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org For additional commands, e-mail: ojb-dev-help@db.apache.org