diff options
| author | David Lamparter <equinox@opensourcerouting.org> | 2024-10-22 20:41:32 +0200 | 
|---|---|---|
| committer | David Lamparter <equinox@opensourcerouting.org> | 2024-10-22 20:43:59 +0200 | 
| commit | 1530a35423ca985b723f2f78e5aac832bc8bacd8 (patch) | |
| tree | 6674f75f5cde6485651dc9db8fe8cb68bfa16d61 /python | |
| parent | fd6f46e9fd3122b64bfefe526c3825b2d109ec22 (diff) | |
vtysh: fix `find` and `list` commands
I simply missed that `node->cmd_vector` is needed for `find` and `list`
to work correctly.
Fixes: #17043
Fixes: 4bc41193e810 ("vtysh, lib: preprocess CLI graphs")
Reported-by: Donald Sharp <sharpd@nvidia.com>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Diffstat (limited to 'python')
| -rw-r--r-- | python/xref2vtysh.py | 4 | 
1 files changed, 3 insertions, 1 deletions
diff --git a/python/xref2vtysh.py b/python/xref2vtysh.py index 0cfb11e721..0e6cdcd6a7 100644 --- a/python/xref2vtysh.py +++ b/python/xref2vtysh.py @@ -450,9 +450,11 @@ class CommandEntry:  	graph_delete_node(node->cmdgraph, vector_slot(node->cmdgraph->nodes, 0));  	vector_free(node->cmdgraph->nodes);  	node->cmdgraph->nodes = &gvec_{node}; -{'}'}  """          ) +        for cmdel in sorted(cmdels): +            ofd.write(f"\tvector_set(node->cmd_vector, &{cmdel}_vtysh);\n") +        ofd.write("}\n")          return [node]  | 
