celix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From abroekh...@apache.org
Subject svn commit: r1620880 - in /celix/trunk/framework/private/src: framework.c service_registry.c
Date Wed, 27 Aug 2014 12:52:46 GMT
Author: abroekhuis
Date: Wed Aug 27 12:52:46 2014
New Revision: 1620880

URL: http://svn.apache.org/r1620880
Log:
Update registry_createServiceReference to use the correct bundle variable as the owner of
the new reference.

Modified:
    celix/trunk/framework/private/src/framework.c
    celix/trunk/framework/private/src/service_registry.c

Modified: celix/trunk/framework/private/src/framework.c
URL: http://svn.apache.org/viewvc/celix/trunk/framework/private/src/framework.c?rev=1620880&r1=1620879&r2=1620880&view=diff
==============================================================================
--- celix/trunk/framework/private/src/framework.c (original)
+++ celix/trunk/framework/private/src/framework.c Wed Aug 27 12:52:46 2014
@@ -1554,7 +1554,6 @@ void fw_serviceChanged(framework_pt fram
 
 				element->listener->serviceChanged(element->listener, event);
 
-//				serviceReference_destroy(event->reference);
 				free(event);
 				//TODO cleanup service reference
 

Modified: celix/trunk/framework/private/src/service_registry.c
URL: http://svn.apache.org/viewvc/celix/trunk/framework/private/src/service_registry.c?rev=1620880&r1=1620879&r2=1620880&view=diff
==============================================================================
--- celix/trunk/framework/private/src/service_registry.c (original)
+++ celix/trunk/framework/private/src/service_registry.c Wed Aug 27 12:52:46 2014
@@ -308,12 +308,13 @@ celix_status_t serviceRegistry_createSer
 
 	// Lock
 	celixThreadMutex_lock(&registry->referencesMapMutex);
-	array_list_pt references = hashMap_get(registry->serviceReferences, bundle);
+	array_list_pt references = hashMap_get(registry->serviceReferences, owner);
 	if (references == NULL) {
 	    arrayList_create(&references);
 	}
+	printf("Registry reference add %p, bundle %p\n", *reference, owner);
 	arrayList_add(references, *reference);
-	hashMap_put(registry->serviceReferences, bundle, references);
+	hashMap_put(registry->serviceReferences, owner, references);
 
 	// Unlock
 	celixThreadMutex_unlock(&registry->referencesMapMutex);



Mime
View raw message