diff options
| author | paul <paul> | 2003-04-19 15:49:49 +0000 | 
|---|---|---|
| committer | paul <paul> | 2003-04-19 15:49:49 +0000 | 
| commit | 73ffb25bec41d729b0dac34d17b6ccd4aa25803b (patch) | |
| tree | 69906ad70c8dd767c51677480f8034a3be3f5edd /ripngd/ripng_routemap.c | |
| parent | 147193a28a19f2f98545b14ad38935423415f53e (diff) | |
Hasso Tepper
http://hasso.linux.ee/zebra/ht-routemap-18042003_5.patch
Trivial fixes to sync daemon's route-map commands to have same syntax. Fixes
a lot of errors with "match ..." and "set ..." commands when using vtysh.
Diffstat (limited to 'ripngd/ripng_routemap.c')
| -rw-r--r-- | ripngd/ripng_routemap.c | 22 | 
1 files changed, 17 insertions, 5 deletions
diff --git a/ripngd/ripng_routemap.c b/ripngd/ripng_routemap.c index f237e6b6b6..832f17c951 100644 --- a/ripngd/ripng_routemap.c +++ b/ripngd/ripng_routemap.c @@ -158,7 +158,9 @@ route_set_metric_compile (char *arg)    if (metric == LONG_MAX || *endptr != '\0')      return NULL; -  if (metric < 0 || metric > RIPNG_METRIC_INFINITY) +  /* Commented out by Hasso Tepper, to avoid problems in vtysh. */ +  /* if (metric < 0 || metric > RIPNG_METRIC_INFINITY) */ +  if (metric < 0)      return NULL;    mod = XMALLOC (MTYPE_ROUTE_MAP_COMPILED,  @@ -314,15 +316,25 @@ DEFUN (set_metric,  DEFUN (no_set_metric,         no_set_metric_cmd, -       "no set metric <0-4294967295>", +       "no set metric",         NO_STR -       "Set value\n" -       "Metric\n" -       "METRIC value\n") +       SET_STR +       "Metric value for destination routing protocol\n")  { +  if (argc == 0) +    return ripng_route_set_delete (vty, vty->index, "metric", NULL); +    return ripng_route_set_delete (vty, vty->index, "metric", argv[0]);  } +ALIAS (no_set_metric, +       no_set_metric_val_cmd, +       "no set metric <0-4294967295>", +       NO_STR +       SET_STR +       "Metric value for destination routing protocol\n" +       "Metric value\n") +  void  ripng_route_map_init ()  {  | 
