Memory leak issue in Secure resources
scan newline '\n' at end of line
Change-Id: I8e7675fef88670ea6f4fc7c38a1b484cc6e28b50
Signed-off-by: Ashwini Kumar <k.ashwini@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/12951
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
(cherry picked from commit
0267c7ab809830f60d4110550f1f9c0bf8b0868f)
Reviewed-on: https://gerrit.iotivity.org/gerrit/12999
{
// Read ACL resource from PS
gAcl = CBORPayloadToAcl(data, size);
+ OICFree(data);
}
/*
* If SVR database in persistent storage got corrupted or
OicUuid_t deviceId = {.id={0}};
memcpy(&deviceId, &doxm->deviceID, sizeof(deviceId));
- OICFree(doxm);
+ DeleteDoxmBinData(doxm);
/* TODO : By assuming that the first response received is the actual
* AMS service, a 'bad device' can cause DoS attack.
memcpy(&pstat->rownerID, &emptyUuid, sizeof(OicUuid_t));
ret = PstatToCBORPayload(pstat, &pstatCbor, &pstatCborLen, false);
- OICFree(pstat);
+ DeletePstatBinData(pstat);
}
if (doxmCbor)
{
memcpy(&doxm->rownerID, &emptyUuid, sizeof(OicUuid_t));
ret = DoxmToCBORPayload(doxm, &doxmCbor, &doxmCborLen, false);
- OICFree(doxm);
+ DeleteDoxmBinData(doxm);
}
{
int request = 0;
scanf("%d", &request);
+ getchar();
switch (request)
{