mirror of
https://github.com/containers/fuse-overlayfs.git
synced 2025-09-10 07:44:54 -04:00
main: fix read after free
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
parent
79c802f61e
commit
7e54c97400
2
main.c
2
main.c
@ -1241,9 +1241,9 @@ insert_node (struct ovl_node *parent, struct ovl_node *item, bool replace)
|
|||||||
old = hash_delete (parent->children, item);
|
old = hash_delete (parent->children, item);
|
||||||
if (old)
|
if (old)
|
||||||
{
|
{
|
||||||
node_free (old);
|
|
||||||
if (node_dirp (old))
|
if (node_dirp (old))
|
||||||
parent->nlinks--;
|
parent->nlinks--;
|
||||||
|
node_free (old);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user