incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cziege...@apache.org
Subject svn commit: r1437573 - /sling/trunk/bundles/resourceresolver/src/main/java/org/apache/sling/resourceresolver/impl/ResourceResolverFactoryActivator.java
Date Wed, 23 Jan 2013 17:04:33 GMT
Author: cziegeler
Date: Wed Jan 23 17:04:33 2013
New Revision: 1437573

URL: http://svn.apache.org/viewvc?rev=1437573&view=rev
Log:
SLING-2713 :  java.lang.IllegalStateException: Service already unregistered during unregistering
of resource resolver 

Modified:
    sling/trunk/bundles/resourceresolver/src/main/java/org/apache/sling/resourceresolver/impl/ResourceResolverFactoryActivator.java

Modified: sling/trunk/bundles/resourceresolver/src/main/java/org/apache/sling/resourceresolver/impl/ResourceResolverFactoryActivator.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/resourceresolver/src/main/java/org/apache/sling/resourceresolver/impl/ResourceResolverFactoryActivator.java?rev=1437573&r1=1437572&r2=1437573&view=diff
==============================================================================
--- sling/trunk/bundles/resourceresolver/src/main/java/org/apache/sling/resourceresolver/impl/ResourceResolverFactoryActivator.java
(original)
+++ sling/trunk/bundles/resourceresolver/src/main/java/org/apache/sling/resourceresolver/impl/ResourceResolverFactoryActivator.java
Wed Jan 23 17:04:33 2013
@@ -299,12 +299,14 @@ public class ResourceResolverFactoryActi
 
     private void unregisterFactory() {
         if ( this.factoryRegistration != null ) {
-            this.factoryRegistration.unregister();
+            final ServiceRegistration local = this.factoryRegistration;
             this.factoryRegistration = null;
+            local.unregister();
         }
         if ( this.factory != null ) {
-            this.factory.deactivate();
+            final ResourceResolverFactoryImpl local = this.factory;
             this.factory = null;
+            local.deactivate();
         }
     }
 



Mime
View raw message