mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-05 01:54:09 +08:00
Btrfs: fix memory leak for name_cache in send/receive
When everything is done, name_cache_free is called which however forgot to call kfree on the cache entries. Signed-off-by: Alexander Block <ablock84@googlemail.com>
This commit is contained in:
parent
adbe7fb6c4
commit
17589bd96e
@ -1822,6 +1822,7 @@ static void name_cache_free(struct send_ctx *sctx)
|
|||||||
|
|
||||||
list_for_each_entry_safe(nce, tmp, &sctx->name_cache_list, list) {
|
list_for_each_entry_safe(nce, tmp, &sctx->name_cache_list, list) {
|
||||||
name_cache_delete(sctx, nce);
|
name_cache_delete(sctx, nce);
|
||||||
|
kfree(nce);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user