IOT-2539 Fix return-type warning 49/22849/2
authorGeorge Nash <george.nash@intel.com>
Mon, 16 Oct 2017 17:16:16 +0000 (10:16 -0700)
committerUze Choi <uzchoi@samsung.com>
Tue, 17 Oct 2017 06:51:41 +0000 (06:51 +0000)
This fixes moved the return value out of the if statment so
the result of the operation will be returned even if
ehRequest->query is null.

Bug: https://jira.iotivity.org/browse/IOT-2539
Bug: https://jira.iotivity.org/browse/IOT-2714
Change-Id: I018776e8800aa51ed9a49a55554949fb869b9495
Signed-off-by: George Nash <george.nash@intel.com>
service/easy-setup/enrollee/src/resourcehandler.c

index 01ab9b5..2c2640b 100644 (file)
@@ -422,10 +422,9 @@ OCEntityHandlerResult updateEasySetupResource(OCEntityHandlerRequest* ehRequest,
             OIC_LOG(DEBUG, ES_RH_TAG, "Handling POST request on default interface");
             updateEasySetupConnectProperty(input);
         }
-    return ehResult;
     }
-
     OIC_LOG(DEBUG, ES_RH_TAG, "updateEasySetupResource exit");
+    return ehResult;
 }
 
 void updateEasySetupConnectProperty(OCRepPayload* input)