summaryrefslogtreecommitdiff
path: root/zebra/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'zebra/main.c')
-rw-r--r--zebra/main.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/zebra/main.c b/zebra/main.c
index 79c9ea7023..b72ce84cd6 100644
--- a/zebra/main.c
+++ b/zebra/main.c
@@ -96,6 +96,7 @@ struct option longopts[] =
{ "vty_addr", required_argument, NULL, 'A'},
{ "vty_port", required_argument, NULL, 'P'},
{ "vty_socket", required_argument, NULL, OPTION_VTYSOCK },
+ { "ecmp", required_argument, NULL, 'e'},
{ "retain", no_argument, NULL, 'r'},
{ "dryrun", no_argument, NULL, 'C'},
#ifdef HAVE_NETLINK
@@ -135,6 +136,8 @@ char config_default[] = SYSCONFDIR DEFAULT_CONFIG_FILE;
/* Process ID saved for use by init system */
const char *pid_file = PATH_ZEBRA_PID;
+unsigned int multipath_num = MULTIPATH_NUM;
+
/* Help information display. */
static void
usage (char *progname, int status)
@@ -328,6 +331,14 @@ main (int argc, char **argv)
case 'A':
vty_addr = optarg;
break;
+ case 'e':
+ multipath_num = atoi (optarg);
+ if (multipath_num > MULTIPATH_NUM || multipath_num <= 0)
+ {
+ zlog_err ("Multipath Number specified must be less than %d and greater than 0", MULTIPATH_NUM);
+ return 1;
+ }
+ break;
case 'i':
pid_file = optarg;
break;