Return-Path: X-Original-To: apmail-celix-commits-archive@www.apache.org Delivered-To: apmail-celix-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id EA52018EF4 for ; Thu, 27 Aug 2015 08:52:45 +0000 (UTC) Received: (qmail 96208 invoked by uid 500); 27 Aug 2015 08:52:45 -0000 Delivered-To: apmail-celix-commits-archive@celix.apache.org Received: (qmail 96178 invoked by uid 500); 27 Aug 2015 08:52:45 -0000 Mailing-List: contact commits-help@celix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@celix.apache.org Delivered-To: mailing list commits@celix.apache.org Received: (qmail 96169 invoked by uid 500); 27 Aug 2015 08:52:45 -0000 Delivered-To: apmail-incubator-celix-commits@incubator.apache.org Received: (qmail 96165 invoked by uid 99); 27 Aug 2015 08:52:45 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 27 Aug 2015 08:52:45 +0000 Date: Thu, 27 Aug 2015 08:52:45 +0000 (UTC) From: "Erjan Altena (JIRA)" To: celix-commits@incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (CELIX-253) Deployment admin does not always download the latest version from ACE MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CELIX-253?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Erjan Altena updated CELIX-253: ------------------------------- Description: The deployment admin does not download a new version from ACE when the deployment version increases from 9.0.0. -> 10.0.0 (and probably also 99.0.0 -> 100.0.0 etc) The cause is the strcmp in the deployment_admin.c: if (admin->current == NULL || strcmp(last, admin->current) > 0) The patch fiel is attched to this issue was: The deployment admin does not download a new version from ACE when the deployment version increases from 9.0.0. -> 10.0.0 (and probably also 99.0.0 -> 100.0.0 etc) The cause is the strcmp in the deployment_admin.c: if (admin->current == NULL || strcmp(last, admin->current) > 0) The patch: ------------------------- diff --git a/deployment_admin/private/src/deployment_admin.c b/deployment_admin/private/src/deployment_admin.c index 6ef80dc..29dd0ff 100644 --- a/deployment_admin/private/src/deployment_admin.c +++ b/deployment_admin/private/src/deployment_admin.c @@ -217,7 +217,7 @@ static void *deploymentAdmin_poll(void *deploymentAdmin) { char *last = arrayList_get(versions, arrayList_size(versions) - 1); if (last != NULL) { - if (admin->current == NULL || strcmp(last, admin->current) > 0) { + if (admin->current == NULL || strcmp(last, admin->current) != 0) { int length = strlen(admin->pollUrl) + strlen(last) + 2; char request[length]; if (admin->current == NULL) { -------------------------- > Deployment admin does not always download the latest version from ACE > --------------------------------------------------------------------- > > Key: CELIX-253 > URL: https://issues.apache.org/jira/browse/CELIX-253 > Project: Celix > Issue Type: Bug > Components: Deployment Admin > Reporter: Erjan Altena > Attachments: patch > > > The deployment admin does not download a new version from ACE when the deployment version increases from 9.0.0. -> 10.0.0 > (and probably also 99.0.0 -> 100.0.0 etc) > The cause is the strcmp in the deployment_admin.c: > if (admin->current == NULL || strcmp(last, admin->current) > 0) > The patch fiel is attched to this issue -- This message was sent by Atlassian JIRA (v6.3.4#6332)