felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rickh...@apache.org
Subject svn commit: r371676 - /incubator/felix/trunk/org.apache.felix.framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java
Date Mon, 23 Jan 2006 21:29:55 GMT
Author: rickhall
Date: Mon Jan 23 13:29:52 2006
New Revision: 371676

URL: http://svn.apache.org/viewcvs?rev=371676&view=rev
Log:
Fixed a bug in my last patch...I was forgetting to remove the bundle
from the service registry after unregistering all of its services.

Modified:
    incubator/felix/trunk/org.apache.felix.framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java

Modified: incubator/felix/trunk/org.apache.felix.framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java
URL: http://svn.apache.org/viewcvs/incubator/felix/trunk/org.apache.felix.framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java?rev=371676&r1=371675&r2=371676&view=diff
==============================================================================
--- incubator/felix/trunk/org.apache.felix.framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java
(original)
+++ incubator/felix/trunk/org.apache.felix.framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java
Mon Jan 23 13:29:52 2006
@@ -84,7 +84,8 @@
     /**
      * This method retrieves all services registrations for the specified
      * bundle and invokes <tt>ServiceRegistration.unregister()</tt> on each
-     * one.
+     * one. This method is only called be the framework to clean up after
+     * a stopped bundle.
      * @param bundle the bundle whose services should be unregistered.
     **/
     public void unregisterServices(Bundle bundle)
@@ -101,6 +102,9 @@
         {
             regs[i].unregister();
         }
+
+        // Now remove the bundle itself.
+        m_serviceRegsMap.remove(bundle);
     }
 
     public synchronized List getServiceReferences(String className, Filter filter)



Mime
View raw message