Make A1.allocate() zero returned memory
This commit is contained in:
parent
8303451929
commit
757f8f8c65
@ -7,6 +7,7 @@ import hulk.hurl;
|
|||||||
import hulk.hippo;
|
import hulk.hippo;
|
||||||
import hulk.util;
|
import hulk.util;
|
||||||
import hulk.pagetable;
|
import hulk.pagetable;
|
||||||
|
import hulk.memory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The A1 memory allocator is a one-shot memory allocator for kernel memory
|
* The A1 memory allocator is a one-shot memory allocator for kernel memory
|
||||||
@ -48,6 +49,8 @@ struct A1
|
|||||||
current_limit += PAGE_SIZE;
|
current_limit += PAGE_SIZE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
memset64(cast(void *)address, 0, size / 8);
|
||||||
|
|
||||||
return cast(void *)address;
|
return cast(void *)address;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user