This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
fixeria gerrit-no-reply at lists.osmocom.orgfixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/19573 )
Change subject: vty/command: cosmetic: simplify conditions in in config_list_cmd
......................................................................
vty/command: cosmetic: simplify conditions in in config_list_cmd
Change-Id: Id1c082d102b7156dafb9c5d9197dcdc4d26bff63
---
M src/vty/command.c
1 file changed, 8 insertions(+), 4 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/73/19573/1
diff --git a/src/vty/command.c b/src/vty/command.c
index 278ceb5..75bc00d 100644
--- a/src/vty/command.c
+++ b/src/vty/command.c
@@ -2858,10 +2858,14 @@
struct cmd_node *cnode = vector_slot(cmdvec, vty->node);
struct cmd_element *cmd;
- for (i = 0; i < vector_active(cnode->cmd_vector); i++)
- if ((cmd = vector_slot(cnode->cmd_vector, i)) != NULL
- && !(cmd->attr & (CMD_ATTR_DEPRECATED | CMD_ATTR_HIDDEN)))
- vty_out(vty, " %s%s", cmd->string, VTY_NEWLINE);
+ for (i = 0; i < vector_active(cnode->cmd_vector); i++) {
+ if ((cmd = vector_slot(cnode->cmd_vector, i)) == NULL)
+ continue;
+ if (cmd->attr & (CMD_ATTR_DEPRECATED | CMD_ATTR_HIDDEN))
+ continue;
+ vty_out(vty, " %s%s", cmd->string, VTY_NEWLINE);
+ }
+
return CMD_SUCCESS;
}
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/19573
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Id1c082d102b7156dafb9c5d9197dcdc4d26bff63
Gerrit-Change-Number: 19573
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200812/53956751/attachment.htm>