diff options
Diffstat (limited to 'src/4a-hal-manager/4a-hal-manager.c')
-rw-r--r-- | src/4a-hal-manager/4a-hal-manager.c | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/src/4a-hal-manager/4a-hal-manager.c b/src/4a-hal-manager/4a-hal-manager.c index da33db8..c587e8a 100644 --- a/src/4a-hal-manager/4a-hal-manager.c +++ b/src/4a-hal-manager/4a-hal-manager.c @@ -78,30 +78,26 @@ static int HalMgrInitApi(afb_api_t apiHandle) if(afb_api_require_api(apiHandle, currentHalData->apiName, 1) || currentHalData->status == HAL_STATUS_INIT_FAILED) { - AFB_API_ERROR(apiHandle, - "Error caught during '%s' api initialization, this api won't be reachable", - currentHalData->apiName); + AFB_API_INFO(apiHandle, + "Error caught during '%s' api initialization, this api won't be reachable", + currentHalData->apiName); toDeleteApiName = strdup(currentHalData->apiName); if(! toDeleteApiName) { AFB_API_ERROR(apiHandle, "Didn't succeed to store (allocate) 'apiName' string"); - return -5; + return -4; } - err = HalUtlRemoveHalDataAndDeleteHalApi(apiHandle, currentHalData, &halMgrData->halDataListHead); + err = InternalHalDeleteApi(apiHandle, &halMgrData->halDataListHead, currentHalData); if(err) { AFB_API_ERROR(apiHandle, - "Error %i happened while trying to delete '%s' api and to remove all its data", + "Error %i happened when tried to delete %s api", err, toDeleteApiName); free(toDeleteApiName); - return -6; + return -5; } - AFB_API_ERROR(apiHandle, - "Api '%s' and all its data has been deleted", - toDeleteApiName); - free(toDeleteApiName); } } |