summaryrefslogtreecommitdiffstats
path: root/ripngd/ripng_offset.c
diff options
context:
space:
mode:
authorQuentin Young <qlyoung@cumulusnetworks.com>2017-06-21 05:10:57 +0200
committerQuentin Young <qlyoung@cumulusnetworks.com>2017-06-29 19:31:28 +0200
commit96ade3ed7716c89b8047a1c0ab3377985d461cf8 (patch)
tree1c3061738c2c0027612b6cdb3e5d5eccb08587bf /ripngd/ripng_offset.c
parentlib: add vty_outln() (diff)
downloadfrr-96ade3ed7716c89b8047a1c0ab3377985d461cf8.tar.xz
frr-96ade3ed7716c89b8047a1c0ab3377985d461cf8.zip
*: use vty_outln
Saves 400 lines Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Diffstat (limited to 'ripngd/ripng_offset.c')
-rw-r--r--ripngd/ripng_offset.c28
1 files changed, 13 insertions, 15 deletions
diff --git a/ripngd/ripng_offset.c b/ripngd/ripng_offset.c
index adb3182a5..51385dd93 100644
--- a/ripngd/ripng_offset.c
+++ b/ripngd/ripng_offset.c
@@ -125,7 +125,7 @@ ripng_offset_list_set (struct vty *vty, const char *alist,
direct = RIPNG_OFFSET_LIST_OUT;
else
{
- vty_out (vty, "Invalid direction: %s%s", direct_str, VTY_NEWLINE);
+ vty_outln (vty, "Invalid direction: %s", direct_str);
return CMD_WARNING;
}
@@ -133,7 +133,7 @@ ripng_offset_list_set (struct vty *vty, const char *alist,
metric = atoi (metric_str);
if (metric < 0 || metric > 16)
{
- vty_out (vty, "Invalid metric: %s%s", metric_str, VTY_NEWLINE);
+ vty_outln (vty, "Invalid metric: %s", metric_str);
return CMD_WARNING;
}
@@ -164,7 +164,7 @@ ripng_offset_list_unset (struct vty *vty, const char *alist,
direct = RIPNG_OFFSET_LIST_OUT;
else
{
- vty_out (vty, "Invalid direction: %s%s", direct_str, VTY_NEWLINE);
+ vty_outln (vty, "Invalid direction: %s", direct_str);
return CMD_WARNING;
}
@@ -172,7 +172,7 @@ ripng_offset_list_unset (struct vty *vty, const char *alist,
metric = atoi (metric_str);
if (metric < 0 || metric > 16)
{
- vty_out (vty, "Invalid metric: %s%s", metric_str, VTY_NEWLINE);
+ vty_outln (vty, "Invalid metric: %s", metric_str);
return CMD_WARNING;
}
@@ -196,7 +196,7 @@ ripng_offset_list_unset (struct vty *vty, const char *alist,
}
else
{
- vty_out (vty, "Can't find offset-list%s", VTY_NEWLINE);
+ vty_outln (vty, "Can't find offset-list");
return CMD_WARNING;
}
return CMD_SUCCESS;
@@ -405,28 +405,26 @@ config_write_ripng_offset_list (struct vty *vty)
if (! offset->ifname)
{
if (offset->direct[RIPNG_OFFSET_LIST_IN].alist_name)
- vty_out (vty, " offset-list %s in %d%s",
+ vty_outln (vty, " offset-list %s in %d",
offset->direct[RIPNG_OFFSET_LIST_IN].alist_name,
- offset->direct[RIPNG_OFFSET_LIST_IN].metric,
- VTY_NEWLINE);
+ offset->direct[RIPNG_OFFSET_LIST_IN].metric);
if (offset->direct[RIPNG_OFFSET_LIST_OUT].alist_name)
- vty_out (vty, " offset-list %s out %d%s",
+ vty_outln (vty, " offset-list %s out %d",
offset->direct[RIPNG_OFFSET_LIST_OUT].alist_name,
- offset->direct[RIPNG_OFFSET_LIST_OUT].metric,
- VTY_NEWLINE);
+ offset->direct[RIPNG_OFFSET_LIST_OUT].metric);
}
else
{
if (offset->direct[RIPNG_OFFSET_LIST_IN].alist_name)
- vty_out (vty, " offset-list %s in %d %s%s",
+ vty_outln (vty, " offset-list %s in %d %s",
offset->direct[RIPNG_OFFSET_LIST_IN].alist_name,
offset->direct[RIPNG_OFFSET_LIST_IN].metric,
- offset->ifname, VTY_NEWLINE);
+ offset->ifname);
if (offset->direct[RIPNG_OFFSET_LIST_OUT].alist_name)
- vty_out (vty, " offset-list %s out %d %s%s",
+ vty_outln (vty, " offset-list %s out %d %s",
offset->direct[RIPNG_OFFSET_LIST_OUT].alist_name,
offset->direct[RIPNG_OFFSET_LIST_OUT].metric,
- offset->ifname, VTY_NEWLINE);
+ offset->ifname);
}
}