mirror of
https://github.com/genodelabs/genode.git
synced 2025-02-11 13:35:27 +00:00
jitterentropy: clear memory in jent_zalloc()
This commit is contained in:
parent
119f679278
commit
41adf8d196
@ -31,7 +31,12 @@ void jitterentropy_init(Genode::Allocator &alloc)
|
|||||||
void *jent_zalloc(size_t len)
|
void *jent_zalloc(size_t len)
|
||||||
{
|
{
|
||||||
if (!_alloc) { return 0; }
|
if (!_alloc) { return 0; }
|
||||||
return _alloc->alloc(len);
|
|
||||||
|
void *p = _alloc->alloc(len);
|
||||||
|
if (p)
|
||||||
|
Genode::memset(p, 0, len);
|
||||||
|
|
||||||
|
return p;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user