Code Review
/
vpp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
adb2c67
)
misc: fix tracedump `show graph` out-of-buffer
63/40063/4
author
Dmitry Valter
<d-valter@yandex-team.com>
Tue, 5 Dec 2023 17:16:57 +0000
(17:16 +0000)
committer
Dave Wallace
<dwallacelf@gmail.com>
Thu, 7 Dec 2023 15:44:43 +0000
(15:44 +0000)
Use the correct string type for vlib_get_node_by_name. Found by ASAN.
Type: fix
Signed-off-by: Dmitry Valter <d-valter@yandex-team.com>
Change-Id: I679d27050487e013e3320a4c558d78fa60c5e98a
src/plugins/tracedump/graph_cli.c
patch
|
blob
|
history
diff --git
a/src/plugins/tracedump/graph_cli.c
b/src/plugins/tracedump/graph_cli.c
index
2440295
..
2de191b
100644
(file)
--- a/
src/plugins/tracedump/graph_cli.c
+++ b/
src/plugins/tracedump/graph_cli.c
@@
-75,9
+75,9
@@
graph_node_show_cmd (vlib_main_t * vm,
while (unformat_check_input (input) != UNFORMAT_END_OF_INPUT)
{
if (unformat (input, "node %d", &index))
-
n = vlib_get_node (vm, index);
- else if (unformat (input, "node %
v
", &name))
-
n = vlib_get_node_by_name (vm, name);
+ n = vlib_get_node (vm, index);
+ else if (unformat (input, "node %
s
", &name))
+ n = vlib_get_node_by_name (vm, name);
else if (unformat (input, "want_arcs"))
want_arcs = true;