mirror of
https://github.com/microsoft/mimalloc.git
synced 2025-07-06 19:38:41 +03:00
merge from dev
This commit is contained in:
commit
c0e1132674
9 changed files with 54 additions and 18 deletions
|
@ -20,8 +20,12 @@ static void test_reserved(void);
|
|||
static void negative_stat(void);
|
||||
static void alloc_huge(void);
|
||||
static void test_heap_walk(void);
|
||||
<<<<<<< HEAD
|
||||
static void test_heap_arena(void);
|
||||
static void test_align(void);
|
||||
=======
|
||||
static void test_canary_leak(void);
|
||||
>>>>>>> dev
|
||||
// static void test_large_pages(void);
|
||||
|
||||
int main() {
|
||||
|
@ -33,7 +37,8 @@ int main() {
|
|||
// double_free2();
|
||||
// corrupt_free();
|
||||
// block_overflow1();
|
||||
block_overflow2();
|
||||
// block_overflow2();
|
||||
test_canary_leak();
|
||||
// test_aslr();
|
||||
// invalid_free();
|
||||
// test_reserved();
|
||||
|
@ -250,6 +255,13 @@ static void test_heap_arena(void) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
static void test_canary_leak(void) {
|
||||
char* p = mi_mallocn_tp(char,23);
|
||||
for(int i = 0; i < 23; i++) {
|
||||
p[i] = '0'+i;
|
||||
}
|
||||
puts(p);
|
||||
free(p);
|
||||
}
|
||||
|
||||
// Experiment with huge OS pages
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue