Fix static analysis defect in NSProviderInterface.c
authorjake <jaehong2.lee@samsung.com>
Wed, 1 Feb 2017 06:09:31 +0000 (15:09 +0900)
committerUze Choi <uzchoi@samsung.com>
Wed, 1 Feb 2017 09:50:26 +0000 (09:50 +0000)
 - Add mutex unlock in exception code.

Change-Id: Ic244e65ee0efb814264e8f1d29ee61f3a42f3e25
Signed-off-by: jake <jaehong2.lee@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/16943
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
service/notification/src/provider/NSProviderInterface.c

index 3f88a0f..0c6d2b1 100644 (file)
@@ -176,6 +176,7 @@ NSResult NSProviderDisableRemoteService(char *serverAddress)
     if (!initProvider || !serverAddress)
     {
         NS_LOG(DEBUG, "Provider service has not been started yet");
+        pthread_mutex_unlock(&nsInitMutex);
         return NS_FAIL;
     }