kernel: add cleanup to data types
Signed-off-by: Michael Shaw <m@michaelsshaw.com>
This commit is contained in:
parent
0f7a2e46cc
commit
69d2fed697
4 changed files with 13 additions and 2 deletions
|
|
@ -106,7 +106,7 @@ void slab_free(mem_cache_t *cache, void *ptr)
|
|||
spinlock_release(&cache->lock);
|
||||
}
|
||||
|
||||
void _cleanup_kfree(void **ptr)
|
||||
void cleanup_kfree(void **ptr)
|
||||
{
|
||||
if (ptr && *ptr)
|
||||
kfree(ptr);
|
||||
|
|
|
|||
Loading…
Reference in a new issue