Function report |
Source Code:lib\test_kasan.c |
Create Date:2022-07-28 06:29:25 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:kmem_cache_double_free
Proto:static noinline void __init kmem_cache_double_free(void)
Type:void
Parameter:Nothing
| 544 | size = 200 |
| 547 | cache = kmem_cache_create("test_cache", size, 0, 0, NULL) |
| 548 | If Not cache Then |
| 549 | pr_err("Cache allocation failed\n") |
| 550 | Return |
| 552 | pr_info("double-free on heap object\n") |
| 553 | p = kmem_cache_alloc(cache, GFP_KERNEL) |
| 554 | If Not p Then |
| 560 | kmem_cache_free(cache, p) |
| 561 | kmem_cache_free(cache, p) |
| 562 | kmem_cache_destroy(cache) |
| Name | Describe |
|---|---|
| kmalloc_tests_init |
| Source code conversion tool public plug-in interface | X |
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |