Fix issues in CA and Routing manager reported by Prevent tool
Change-Id: I855181fa12e8e8b483f48c071fa6e12de9b94c2c
Signed-off-by: Sandipan Patra <sandipan.p@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/3857
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Abhishek Pandey <abhi.siso@samsung.com>
Reviewed-by: Abhishek Sharma <ce.abhishek@samsung.com>
Reviewed-by: Jon A. Cruz <jonc@osg.samsung.com>
(*linklist)->size -= 1;
}
+
+ OICFree(*linklist);
*linklist=NULL;
return CA_STATUS_OK;
while (NULL != iterTable)
{
RTMGatewayEntry_t *entry = u_linklist_get_data(iterTable);
- if (NULL == entry && NULL == entry->destination)
+ if (NULL == entry || NULL == entry->destination)
{
OC_LOG(ERROR, TAG, "entry is NULL");
return false;