mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-08-03 20:54:41 +02:00
formating and removing white space, also added sanity check on blob arguments
This commit is contained in:
@@ -215,7 +215,8 @@ int wc_caamCreateBlob(byte* data, word32 dataSz, byte* out, word32* outSz)
|
||||
int ret;
|
||||
word32 local[2] = {0,0};
|
||||
|
||||
if (*outSz < dataSz + WC_CAAM_BLOB_SZ) {
|
||||
if (data == NULL || out == NULL || outSz == NULL ||
|
||||
*outSz < dataSz + WC_CAAM_BLOB_SZ) {
|
||||
return BAD_FUNC_ARG;
|
||||
}
|
||||
|
||||
@@ -250,7 +251,8 @@ int wc_caamOpenBlob(byte* data, word32 dataSz, byte* out, word32* outSz)
|
||||
int ret;
|
||||
word32 local[2] = {0,0};
|
||||
|
||||
if (*outSz < dataSz - WC_CAAM_BLOB_SZ) {
|
||||
if (data == NULL || out == NULL || outSz == NULL ||
|
||||
*outSz < dataSz - WC_CAAM_BLOB_SZ) {
|
||||
return BAD_FUNC_ARG;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user