From c473da3611fecc3dea19d42d194e4c6046d8150e Mon Sep 17 00:00:00 2001 From: Ioannis Canellos Date: Tue, 17 Jan 2012 00:35:24 +0200 Subject: [PATCH] JCloudsVersion now uses the classloader that loaded the class instead of the TCCL --- core/src/main/java/org/jclouds/JcloudsVersion.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/main/java/org/jclouds/JcloudsVersion.java b/core/src/main/java/org/jclouds/JcloudsVersion.java index 016d1ea1f4..aeccd39f71 100644 --- a/core/src/main/java/org/jclouds/JcloudsVersion.java +++ b/core/src/main/java/org/jclouds/JcloudsVersion.java @@ -65,7 +65,7 @@ public class JcloudsVersion { private static String readVersionPropertyFromClasspath() { Properties versionProperties = new Properties(); try { - versionProperties.load(checkNotNull(Thread.currentThread().getContextClassLoader().getResourceAsStream(VERSION_RESOURCE_FILE), VERSION_RESOURCE_FILE)); + versionProperties.load(checkNotNull(JcloudsVersion.class.getClassLoader().getResourceAsStream(VERSION_RESOURCE_FILE), VERSION_RESOURCE_FILE)); } catch (IOException exception) { throw new IllegalStateException(format("Unable to load version resource file '%s'", VERSION_RESOURCE_FILE), exception); }