Skip to content

Commit 5fb4874

Browse files
committed
data tree BUGFIX possible illegal pointer cleared
Fixes #390
1 parent 4c3f385 commit 5fb4874

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/tree_data.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4303,6 +4303,9 @@ lyd_validate(struct lyd_node **node, int options, void *var_arg)
43034303
if (to_free) {
43044304
if ((*node) == to_free) {
43054305
*node = NULL;
4306+
if (data_tree == to_free) {
4307+
data_tree = NULL;
4308+
}
43064309
}
43074310
lyd_free(to_free);
43084311
to_free = NULL;

0 commit comments

Comments
 (0)