You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by gh...@apache.org on 2019/12/21 08:47:46 UTC
[sling-org-apache-sling-installer-provider-installhook] 01/05:
SLING-8949 Handle two digits versions correctly
This is an automated email from the ASF dual-hosted git repository.
ghenzler pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-installer-provider-installhook.git
commit f45a29a581980d15974e530263d91a5d435829d3
Author: georg.henzler <ge...@netcentric.biz>
AuthorDate: Sat Dec 21 00:24:55 2019 +0100
SLING-8949 Handle two digits versions correctly
---
.../apache/sling/installer/provider/installhook/OsgiInstallerHook.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/main/java/org/apache/sling/installer/provider/installhook/OsgiInstallerHook.java b/src/main/java/org/apache/sling/installer/provider/installhook/OsgiInstallerHook.java
index 6ca0eec..e9c6c44 100644
--- a/src/main/java/org/apache/sling/installer/provider/installhook/OsgiInstallerHook.java
+++ b/src/main/java/org/apache/sling/installer/provider/installhook/OsgiInstallerHook.java
@@ -258,7 +258,7 @@ public class OsgiInstallerHook implements InstallHook {
if (resource.getState() == ResourceState.INSTALLED) {
String currentlyActiveBundleVersion = resource.getVersion().toString();
- if (!StringUtils.equals(currentlyActiveBundleVersion, bundle.version)) {
+ if (!StringUtils.startsWith(currentlyActiveBundleVersion, bundle.version)) {
logger.log("Bundle " + bundle.symbolicName + " is installed with version "
+ currentlyActiveBundleVersion + " but package contains version " + bundle.version);
needsInstallation = true;