celix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pnol...@apache.org
Subject [celix] branch develop updated: gh-91: reenables rsa tests and fixes an issue with handling avpr or dfi descriptors
Date Mon, 20 Jan 2020 20:23:15 GMT
This is an automated email from the ASF dual-hosted git repository.

pnoltes pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/celix.git


The following commit(s) were added to refs/heads/develop by this push:
     new 52866d1  gh-91: reenables rsa tests and fixes an issue with handling avpr or dfi
descriptors
52866d1 is described below

commit 52866d1bb5bf17c5f04bb0c517e69d6f942a1cc8
Author: Pepijn Noltes <pepijnnoltes@gmail.com>
AuthorDate: Mon Jan 20 21:22:35 2020 +0100

    gh-91: reenables rsa tests and fixes an issue with handling avpr or dfi descriptors
---
 .travis.yml                                                           | 4 ++--
 .../remote_service_admin_dfi/src/export_registration_dfi.c            | 4 ++--
 .../remote_service_admin_dfi/src/import_registration_dfi.c            | 4 ++--
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/.travis.yml b/.travis.yml
index 8fb0dc8..8936920 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -64,8 +64,8 @@ before_script:
     - cd -
     - mkdir build install
     - export BUILD_OPTIONS=" \
-        -DBUILD_REMOTE_SERVICE_ADMIN=OFF \
-        -DBUILD_RSA_REMOTE_SERVICE_ADMIN_DFI=OFF \
+        -DBUILD_REMOTE_SERVICE_ADMIN=ON \
+        -DBUILD_RSA_REMOTE_SERVICE_ADMIN_DFI=ON \
         -DBUILD_DEPLOYMENT_ADMIN=ON \
         -DBUILD_DEPENDENCY_MANAGER=ON \
         -DBUILD_EXAMPLES=ON -DBUILD_LOG_SERVICE=ON \
diff --git a/bundles/remote_services/remote_service_admin_dfi/src/export_registration_dfi.c
b/bundles/remote_services/remote_service_admin_dfi/src/export_registration_dfi.c
index 9558616..b1cc1f2 100644
--- a/bundles/remote_services/remote_service_admin_dfi/src/export_registration_dfi.c
+++ b/bundles/remote_services/remote_service_admin_dfi/src/export_registration_dfi.c
@@ -154,7 +154,7 @@ static celix_status_t exportRegistration_findAndParseInterfaceDescriptor(log_hel
     FILE* descriptor = NULL;
 
     celix_status_t status = dfi_findDescriptor(context, bundle, name, &descriptor);
-    if (status == CELIX_SUCCESS) {
+    if (status == CELIX_SUCCESS && descriptor != NULL) {
         int rc = dynInterface_parse(descriptor, out);
         fclose(descriptor);
         if (rc != 0) {
@@ -165,7 +165,7 @@ static celix_status_t exportRegistration_findAndParseInterfaceDescriptor(log_hel
     }
 
     status = dfi_findAvprDescriptor(context, bundle, name, &descriptor);
-    if (status == CELIX_SUCCESS) {
+    if (status == CELIX_SUCCESS && descriptor != NULL) {
         *out = dynInterface_parseAvpr(descriptor);
         if (*out == NULL) {
             logHelper_log(helper, OSGI_LOGSERVICE_WARNING, "RSA_AVPR: Error parsing avpr
service descriptor for '%s'", name);
diff --git a/bundles/remote_services/remote_service_admin_dfi/src/import_registration_dfi.c
b/bundles/remote_services/remote_service_admin_dfi/src/import_registration_dfi.c
index be1f297..fc01587 100644
--- a/bundles/remote_services/remote_service_admin_dfi/src/import_registration_dfi.c
+++ b/bundles/remote_services/remote_service_admin_dfi/src/import_registration_dfi.c
@@ -209,7 +209,7 @@ static celix_status_t importRegistration_findAndParseInterfaceDescriptor(celix_b
     celix_status_t status = CELIX_SUCCESS;
     FILE* descriptor = NULL;
     status = dfi_findDescriptor(context, bundle, name, &descriptor);
-    if (status == CELIX_SUCCESS) {
+    if (status == CELIX_SUCCESS && descriptor != NULL) {
         int rc = dynInterface_parse(descriptor, out);
         fclose(descriptor);
         if (rc != 0) {
@@ -220,7 +220,7 @@ static celix_status_t importRegistration_findAndParseInterfaceDescriptor(celix_b
     }
 
     status = dfi_findAvprDescriptor(context, bundle, name, &descriptor);
-    if (status == CELIX_SUCCESS) {
+    if (status == CELIX_SUCCESS && descriptor != NULL) {
         *out = dynInterface_parseAvpr(descriptor);
         fclose(descriptor);
         if (*out == NULL) {


Mime
View raw message