karaf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbono...@apache.org
Subject karaf-cellar git commit: [KARAF-2250] Fix version retrieval in bundle listener
Date Wed, 14 Jan 2015 18:39:12 GMT
Repository: karaf-cellar
Updated Branches:
  refs/heads/cellar-2.3.x 602459b59 -> 2b920267c


[KARAF-2250] Fix version retrieval in bundle listener


Project: http://git-wip-us.apache.org/repos/asf/karaf-cellar/repo
Commit: http://git-wip-us.apache.org/repos/asf/karaf-cellar/commit/2b920267
Tree: http://git-wip-us.apache.org/repos/asf/karaf-cellar/tree/2b920267
Diff: http://git-wip-us.apache.org/repos/asf/karaf-cellar/diff/2b920267

Branch: refs/heads/cellar-2.3.x
Commit: 2b920267c8a669990b179cbfd295dc60632fc5bd
Parents: 602459b
Author: Jean-Baptiste Onofré <jbonofre@apache.org>
Authored: Wed Jan 14 19:38:42 2015 +0100
Committer: Jean-Baptiste Onofré <jbonofre@apache.org>
Committed: Wed Jan 14 19:38:42 2015 +0100

----------------------------------------------------------------------
 .../java/org/apache/karaf/cellar/bundle/LocalBundleListener.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/2b920267/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java
----------------------------------------------------------------------
diff --git a/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java
b/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java
index c1ba8ed..8b642f0 100644
--- a/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java
+++ b/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java
@@ -88,7 +88,7 @@ public class LocalBundleListener extends BundleSupport implements SynchronousBun
                     // if there is no symbolic name, resort to location.
                     name = (name == null) ? event.getBundle().getLocation() : name;
                     String symbolicName = event.getBundle().getSymbolicName();
-                    String version = event.getBundle().getVersion().toString();
+                    String version = event.getBundle().getHeaders().get(org.osgi.framework.Constants.BUNDLE_VERSION);
                     String bundleLocation = event.getBundle().getLocation();
                     int type = event.getType();
                     if (isAllowed(group, Constants.CATEGORY, bundleLocation, EventType.OUTBOUND))
{


Mime
View raw message