summaryrefslogtreecommitdiffstats
path: root/eigrpd/eigrp_vty.c
diff options
context:
space:
mode:
authorDaniel Walton <dwalton@cumulusnetworks.com>2017-07-13 21:56:08 +0200
committerDaniel Walton <dwalton@cumulusnetworks.com>2017-07-13 21:56:08 +0200
commitf1a05de982b2466907838a7e74d7d15ad4060db2 (patch)
treea41d430cf69e6603accec78238c8d86d59a389ad /eigrpd/eigrp_vty.c
parentMerge pull request #807 from Jafaral/qua2frr (diff)
downloadfrr-f1a05de982b2466907838a7e74d7d15ad4060db2.tar.xz
frr-f1a05de982b2466907838a7e74d7d15ad4060db2.zip
vtysh: return non-zero for configuration failures
Signed-off-by: Daniel Walton <dwalton@cumulusnetworks.com> This allows frr-reload.py (or anything else that scripts via vtysh) to know if the vtysh command worked or hit an error.
Diffstat (limited to 'eigrpd/eigrp_vty.c')
-rw-r--r--eigrpd/eigrp_vty.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/eigrpd/eigrp_vty.c b/eigrpd/eigrp_vty.c
index e283c7365..5b48ab79b 100644
--- a/eigrpd/eigrp_vty.c
+++ b/eigrpd/eigrp_vty.c
@@ -236,7 +236,7 @@ DEFUN (no_router_eigrp,
if (eigrp->AS != atoi (argv[3]->arg))
{
vty_outln (vty,"%% Attempting to deconfigure non-existent AS");
- return CMD_WARNING;
+ return CMD_WARNING_CONFIG_FAILED;
}
eigrp_finish_final (eigrp);
@@ -394,7 +394,7 @@ DEFUN (eigrp_network,
if (ret == 0)
{
vty_outln (vty, "There is already same network statement.");
- return CMD_WARNING;
+ return CMD_WARNING_CONFIG_FAILED;
}
return CMD_SUCCESS;
@@ -418,7 +418,7 @@ DEFUN (no_eigrp_network,
if (ret == 0)
{
vty_outln (vty,"Can't find specified network configuration.");
- return CMD_WARNING;
+ return CMD_WARNING_CONFIG_FAILED;
}
return CMD_SUCCESS;
@@ -866,7 +866,7 @@ str2auth_type (const char *str, struct interface *ifp)
{
/* Sanity check. */
if (str == NULL)
- return CMD_WARNING;
+ return CMD_WARNING_CONFIG_FAILED;
if(strncmp(str, "md5",3) == 0)
{
@@ -879,7 +879,7 @@ str2auth_type (const char *str, struct interface *ifp)
return CMD_SUCCESS;
}
- return CMD_WARNING;
+ return CMD_WARNING_CONFIG_FAILED;
}
DEFUN (eigrp_authentication_mode,
@@ -1032,7 +1032,7 @@ DEFUN (eigrp_redistribute_source_metric,
argv_find (argv, argc, "redistribute", &idx);
source = proto_redistnum(AFI_IP, argv[idx+1]->arg);
if (source < 0 )
- return CMD_WARNING;
+ return CMD_WARNING_CONFIG_FAILED;
/* Get metrics values */
@@ -1061,7 +1061,7 @@ DEFUN (no_eigrp_redistribute_source_metric,
argv_find (argv, argc, "redistribute", &idx);
source = proto_redistnum(AFI_IP, argv[idx+1]->arg);
if (source < 0 )
- return CMD_WARNING;
+ return CMD_WARNING_CONFIG_FAILED;
/* Get metrics values */