Return-Path: X-Original-To: apmail-aries-commits-archive@www.apache.org Delivered-To: apmail-aries-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7ADE4CCEB for ; Tue, 14 Aug 2012 07:55:00 +0000 (UTC) Received: (qmail 36640 invoked by uid 500); 14 Aug 2012 07:55:00 -0000 Delivered-To: apmail-aries-commits-archive@aries.apache.org Received: (qmail 36408 invoked by uid 500); 14 Aug 2012 07:54:54 -0000 Mailing-List: contact commits-help@aries.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@aries.apache.org Delivered-To: mailing list commits@aries.apache.org Received: (qmail 36368 invoked by uid 99); 14 Aug 2012 07:54:52 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 14 Aug 2012 07:54:52 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 14 Aug 2012 07:54:50 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id D9EEB23888E3; Tue, 14 Aug 2012 07:54:04 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1372759 - /aries/trunk/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/namespace/NamespaceHandlerRegistryImpl.java Date: Tue, 14 Aug 2012 07:54:04 -0000 To: commits@aries.apache.org From: cumminsh@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20120814075404.D9EEB23888E3@eris.apache.org> Author: cumminsh Date: Tue Aug 14 07:54:04 2012 New Revision: 1372759 URL: http://svn.apache.org/viewvc?rev=1372759&view=rev Log: [ARIES-899] Backing out change, since it doesn't compile (missing lock variable) Modified: aries/trunk/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/namespace/NamespaceHandlerRegistryImpl.java Modified: aries/trunk/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/namespace/NamespaceHandlerRegistryImpl.java URL: http://svn.apache.org/viewvc/aries/trunk/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/namespace/NamespaceHandlerRegistryImpl.java?rev=1372759&r1=1372758&r2=1372759&view=diff ============================================================================== --- aries/trunk/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/namespace/NamespaceHandlerRegistryImpl.java (original) +++ aries/trunk/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/namespace/NamespaceHandlerRegistryImpl.java Tue Aug 14 07:54:04 2012 @@ -414,26 +414,14 @@ public class NamespaceHandlerRegistryImp protected synchronized void removeSchemasFor(NamespaceHandler handler) { List> keys = new ArrayList>(); - lock.readLock().lock(); - try { - for (Map key : schemas.keySet()) { - if (key.values().contains(handler)) { - keys.add(key); - } - } - } finally { - lock.readLock().unlock(); - } - if (!keys.isEmpty()) { - lock.writeLock().lock(); - try { - for (Map key : keys) { - schemas.remove(key); - } - } finally { - lock.writeLock().unlock(); + for (Map key : schemas.keySet()) { + if (key.values().contains(handler)) { + keys.add(key); } } + for (Map key : keys) { + schemas.remove(key); + } } private SchemaFactory getSchemaFactory() {