OICFree(serial);
OICFree(certificate);
- if (NULL != f)
- {
- if (0 != fclose(f))
- {
- printf("Warning: failed to fclose\n");
- }
- }
}
static void DoGenKeyPair()
break;
}
}
-}
\ No newline at end of file
+}
goto no_memory;
}
- int acllist_count = 0;
+ size_t acllist_count = 0;
//code below duplicates LL_COUNT, implemented in newer version of utlist.h
{
cloudAce_t *ace = (cloudAce_t*)aces;
OICFree(uuid);
- int reslist_count = 0;
+ size_t reslist_count = 0;
//code below duplicates LL_COUNT, implemented in newer version of utlist.h
{
OicSecRsrc_t *res = ace->resources;
goto no_memory;
}
- int acllist_count = 1;
+ size_t acllist_count = 1;
helperPayload = OICCalloc(acllist_count, sizeof(OCRepPayload *));
if (!helperPayload)
OICFree(uuid);
- int reslist_count = 0;
+ size_t reslist_count = 0;
//code below duplicates LL_COUNT, implemented in newer version of utlist.h
{
OicSecRsrc_t *res = ace->resources;
{
OIC_LOG(ERROR, TAG, "Certiface not read completely");
}
- fclose(fp);
}
+ fclose(fp);
}
OIC_LOG_BUFFER(DEBUG, TAG, trustCertChainArray.data, trustCertChainArray.len);
{
OIC_LOG(ERROR,TAG,"Read error");
}
- fclose(fp);
}
+ fclose(fp);
}
OIC_LOG_BUFFER(DEBUG, TAG, trustCertChainArray.data, trustCertChainArray.len);
memcpy(number, verifNum, MUTUAL_VERIF_NUM_LEN);
}
- return context->callback(number);
+ OCStackResult res = context->callback(number);
+ delete context;
+ return res;
}
OCStackResult OCSecure::registerDisplayNumCallback(DisplayNumCB displayNumCB)
return OC_STACK_INVALID_PARAM;
}
- return context->callback();
+ OCStackResult res = context->callback();
+ delete context;
+ return res;
}
OCStackResult OCSecure::registerUserConfirmCallback(UserConfirmNumCB userConfirmCB)