mirror of
https://github.com/dgibson/dtc.git
synced 2025-10-13 16:27:39 -04:00
Let get_subnode() not return deleted nodes
Both current callers actually don't want deleted nodes returned by get_subnode(). So change semantics of this function to only return "live" nodes. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
175d2a564c
commit
4ea851f5a4
1 changed files with 1 additions and 1 deletions
|
@ -504,7 +504,7 @@ struct node *get_subnode(struct node *node, const char *nodename)
|
||||||
struct node *child;
|
struct node *child;
|
||||||
|
|
||||||
for_each_child(node, child)
|
for_each_child(node, child)
|
||||||
if (streq(child->name, nodename))
|
if (streq(child->name, nodename) && !child->deleted)
|
||||||
return child;
|
return child;
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue