diff options
-rw-r--r-- | location/LocationAPIClientBase.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/location/LocationAPIClientBase.cpp b/location/LocationAPIClientBase.cpp index 465b76d..d8eae3f 100644 --- a/location/LocationAPIClientBase.cpp +++ b/location/LocationAPIClientBase.cpp @@ -600,6 +600,7 @@ void LocationAPIClientBase::locAPIRemoveGeofences(size_t count, uint32_t* ids) if (sessions == NULL) { LOC_LOGE("%s:%d] Failed to allocate %d bytes !", __FUNCTION__, __LINE__, sizeof(uint32_t) * count); + pthread_mutex_unlock(&mMutex); return; } @@ -634,6 +635,7 @@ void LocationAPIClientBase::locAPIModifyGeofences( if (sessions == NULL) { LOC_LOGE("%s:%d] Failed to allocate %d bytes !", __FUNCTION__, __LINE__, sizeof(uint32_t) * count); + pthread_mutex_unlock(&mMutex); return; } @@ -668,6 +670,7 @@ void LocationAPIClientBase::locAPIPauseGeofences(size_t count, uint32_t* ids) if (sessions == NULL) { LOC_LOGE("%s:%d] Failed to allocate %d bytes !", __FUNCTION__, __LINE__, sizeof(uint32_t) * count); + pthread_mutex_unlock(&mMutex); return; } @@ -702,6 +705,7 @@ void LocationAPIClientBase::locAPIResumeGeofences( if (sessions == NULL) { LOC_LOGE("%s:%d] Failed to allocate %d bytes !", __FUNCTION__, __LINE__, sizeof(uint32_t) * count); + pthread_mutex_unlock(&mMutex); return; } @@ -740,6 +744,7 @@ void LocationAPIClientBase::locAPIRemoveAllGeofences() if (sessions == NULL) { LOC_LOGE("%s:%d] Failed to allocate %d bytes !", __FUNCTION__, __LINE__, sizeof(uint32_t) * count); + pthread_mutex_unlock(&mMutex); return; } |