Fix -Wreturn-type build warning 37/229537/1 accepted/tizen/unified/20200407.130847 submit/tizen/20200402.005546 submit/tizen/20200403.000136 submit/tizen/20200405.215959
authorDoHyun Pyun <dh79.pyun@samsung.com>
Wed, 1 Apr 2020 22:55:52 +0000 (07:55 +0900)
committerDoHyun Pyun <dh79.pyun@samsung.com>
Wed, 1 Apr 2020 22:58:26 +0000 (07:58 +0900)
With new toolchain gcc9.2, these cases go to 100%
crash. So Must Fix this warning error.

Change-Id: I8354a2d6c57d2da16feca5151e1b5ebe99be55fe
Signed-off-by: DoHyun Pyun <dh79.pyun@samsung.com>
resource/csdk/connectivity/src/bt_le_adapter/tizen/caleclient.c
service/notification/src/provider/NSProviderTopic.c

index c13d8e2..7c5f6c8 100755 (executable)
@@ -1320,7 +1320,8 @@ static CAResult_t CALEGattConnectionRetry(const char *remoteAddress)
 {
     OIC_LOG(DEBUG, TAG, "IN");
 
-    VERIFY_NON_NULL_VOID(remoteAddress, TAG, "remote address is NULL")
+    VERIFY_NON_NULL_RET(remoteAddress, TAG,
+                        "remote address is NULL", CA_STATUS_FAILED);
 
     CALEGattDisConnect(remoteAddress);
     CALEWaittillDisconnect(g_isDisconnectedMutex, g_LEDisconnectedCond, 10);
@@ -1808,4 +1809,4 @@ CAResult_t CALEClientSendNegotiationMessage(const char* address)
     //@Todo
     //it will be implemented when tizen public 3.0 is released.
     return CA_NOT_SUPPORTED;
-}
\ No newline at end of file
+}
index b745659..9b3da30 100644 (file)
@@ -310,7 +310,7 @@ NSResult NSSendTopicList(OCEntityHandlerRequest * entityHandlerRequest)
             {
                 NS_LOG_V(ERROR, "payloadTopicArray[%d] is NULL", i);
                 NSOICFree(payloadTopicArray);
-                return;
+                return NS_ERROR;
             }
 
             OCRepPayloadSetPropString(payloadTopicArray[i], NS_ATTRIBUTE_TOPIC_NAME,