mirror of
https://github.com/cuberite/polarssl.git
synced 2025-09-13 09:05:08 -04:00
Add mac not NULL check before calling memset
Signed-off-by: Thomas Daubney <thomas.daubney@arm.com>
This commit is contained in:
parent
301491d70c
commit
480347d682
@ -2687,7 +2687,7 @@ exit:
|
|||||||
operation->mac_size = 0;
|
operation->mac_size = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mac_size > operation->mac_size) {
|
if ((mac != NULL) && (mac_size > operation->mac_size)) {
|
||||||
memset(&mac[operation->mac_size], '!',
|
memset(&mac[operation->mac_size], '!',
|
||||||
mac_size - operation->mac_size);
|
mac_size - operation->mac_size);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user