celix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From abroekh...@apache.org
Subject svn commit: r1658956 - /celix/trunk/framework/private/src/framework.c
Date Wed, 11 Feb 2015 13:45:02 GMT
Author: abroekhuis
Date: Wed Feb 11 13:45:02 2015
New Revision: 1658956

URL: http://svn.apache.org/r1658956
Log:
CELIX-219: Fixed memory leak

If the logger is not set via the configuration, it has to be destroyed by the framework when
stopping.

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

Modified: celix/trunk/framework/private/src/framework.c
URL: http://svn.apache.org/viewvc/celix/trunk/framework/private/src/framework.c?rev=1658956&r1=1658955&r2=1658956&view=diff
==============================================================================
--- celix/trunk/framework/private/src/framework.c (original)
+++ celix/trunk/framework/private/src/framework.c Wed Feb 11 13:45:02 2015
@@ -277,6 +277,10 @@ celix_status_t framework_destroy(framewo
 
 	unsetenv(OSGI_FRAMEWORK_FRAMEWORK_UUID);
 
+	logger = hashMap_get(framework->configurationMap, "logger");
+	if (logger == NULL) {
+		free(framework->logger);
+	}
 	free(framework);
 
 	return status;



Mime
View raw message