mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-06 12:52:49 +00:00
lib: argv update for thread.c
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
This commit is contained in:
parent
97e5b7c0b3
commit
1bf1b05af9
16
lib/thread.c
16
lib/thread.c
@ -302,12 +302,12 @@ DEFUN (show_thread_cpu,
|
||||
int i = 0;
|
||||
thread_type filter = (thread_type) -1U;
|
||||
|
||||
if (argc > 0)
|
||||
if (argc > 3)
|
||||
{
|
||||
filter = 0;
|
||||
while (argv[0][i] != '\0')
|
||||
while (argv[3]->arg[i] != '\0')
|
||||
{
|
||||
switch ( argv[0][i] )
|
||||
switch ( argv[3]->arg[i] )
|
||||
{
|
||||
case 'r':
|
||||
case 'R':
|
||||
@ -342,7 +342,7 @@ DEFUN (show_thread_cpu,
|
||||
{
|
||||
vty_out(vty, "Invalid filter \"%s\" specified,"
|
||||
" must contain at least one of 'RWTEXB'%s",
|
||||
argv[0], VTY_NEWLINE);
|
||||
argv[3]->arg, VTY_NEWLINE);
|
||||
return CMD_WARNING;
|
||||
}
|
||||
}
|
||||
@ -384,12 +384,12 @@ DEFUN (clear_thread_cpu,
|
||||
int i = 0;
|
||||
thread_type filter = (thread_type) -1U;
|
||||
|
||||
if (argc > 0)
|
||||
if (argc > 3)
|
||||
{
|
||||
filter = 0;
|
||||
while (argv[0][i] != '\0')
|
||||
while (argv[3]->arg[i] != '\0')
|
||||
{
|
||||
switch ( argv[0][i] )
|
||||
switch ( argv[3]->arg[i] )
|
||||
{
|
||||
case 'r':
|
||||
case 'R':
|
||||
@ -424,7 +424,7 @@ DEFUN (clear_thread_cpu,
|
||||
{
|
||||
vty_out(vty, "Invalid filter \"%s\" specified,"
|
||||
" must contain at least one of 'RWTEXB'%s",
|
||||
argv[0], VTY_NEWLINE);
|
||||
argv[3]->arg, VTY_NEWLINE);
|
||||
return CMD_WARNING;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user