- ocpayloadparse : double free
- occollection : need to NULL check
- ocRepresentation : big size of m_devAddr parameter
Change-Id: I5bd4cbc6d5dab1dfe7293a234e90d2c465a0039c
Signed-off-by: ChaJiWon <jw_wonny.cha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/17007
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
{
ifQueryParam = OICStrdup(OC_RSRVD_INTERFACE_LL);
}
+
+ VERIFY_PARAM_NON_NULL(TAG, ifQueryParam, "Invalid Parameter ifQueryParam");
+
if (0 == strcmp(ifQueryParam, OC_RSRVD_INTERFACE_LL) || 0 == strcmp (ifQueryParam, OC_RSRVD_INTERFACE_DEFAULT))
{
if (ehRequest->method == OC_REST_PUT || ehRequest->method == OC_REST_POST)
{
err = cbor_value_advance(&repMap);
free(name); // Free *TinyCBOR allocated* string.
+ name = NULL;
continue;
}
}
virtual ~OCRepresentation(){}
- void setDevAddr(const OCDevAddr addr);
+ void setDevAddr(const OCDevAddr&);
const std::string getHost() const;
m_children = children;
}
- void OCRepresentation::setDevAddr(const OCDevAddr m_devAddr)
+ void OCRepresentation::setDevAddr(const OCDevAddr& m_devAddr)
{
std::ostringstream ss;
if (m_devAddr.flags & OC_SECURE)