summaryrefslogtreecommitdiff
path: root/proto/ospf
diff options
context:
space:
mode:
Diffstat (limited to 'proto/ospf')
-rw-r--r--proto/ospf/config.Y16
-rw-r--r--proto/ospf/ospf.c2
-rw-r--r--proto/ospf/ospf.h2
3 files changed, 10 insertions, 10 deletions
diff --git a/proto/ospf/config.Y b/proto/ospf/config.Y
index 9669b708..38b09deb 100644
--- a/proto/ospf/config.Y
+++ b/proto/ospf/config.Y
@@ -504,29 +504,29 @@ dynamic_attr: OSPF_TAG { $$ = f_new_dynamic_attr(EAF_TYPE_INT, 0, T_INT, EA_OSPF
dynamic_attr: OSPF_ROUTER_ID { $$ = f_new_dynamic_attr(EAF_TYPE_ROUTER_ID, 0, T_QUAD, EA_OSPF_ROUTER_ID); } ;
CF_CLI_HELP(SHOW OSPF, ..., [[Show information about OSPF protocol]]);
-CF_CLI(SHOW OSPF, optsym, [<name>], [[Show information about OSPF protocol]])
+CF_CLI(SHOW OSPF, optproto, [<name>], [[Show information about OSPF protocol]])
{ ospf_sh(proto_get_named($3, &proto_ospf)); };
-CF_CLI(SHOW OSPF NEIGHBORS, optsym opttext, [<name>] [\"<interface>\"], [[Show information about OSPF neighbors]])
+CF_CLI(SHOW OSPF NEIGHBORS, optproto opttext, [<name>] [\"<interface>\"], [[Show information about OSPF neighbors]])
{ ospf_sh_neigh(proto_get_named($4, &proto_ospf), $5); };
-CF_CLI(SHOW OSPF INTERFACE, optsym opttext, [<name>] [\"<interface>\"], [[Show information about interface]])
+CF_CLI(SHOW OSPF INTERFACE, optproto opttext, [<name>] [\"<interface>\"], [[Show information about interface]])
{ ospf_sh_iface(proto_get_named($4, &proto_ospf), $5); };
CF_CLI_HELP(SHOW OSPF TOPOLOGY, [all] [<name>], [[Show information about OSPF network topology]])
-CF_CLI(SHOW OSPF TOPOLOGY, optsym opttext, [<name>], [[Show information about reachable OSPF network topology]])
+CF_CLI(SHOW OSPF TOPOLOGY, optproto opttext, [<name>], [[Show information about reachable OSPF network topology]])
{ ospf_sh_state(proto_get_named($4, &proto_ospf), 0, 1); };
-CF_CLI(SHOW OSPF TOPOLOGY ALL, optsym opttext, [<name>], [[Show information about all OSPF network topology]])
+CF_CLI(SHOW OSPF TOPOLOGY ALL, optproto opttext, [<name>], [[Show information about all OSPF network topology]])
{ ospf_sh_state(proto_get_named($5, &proto_ospf), 0, 0); };
CF_CLI_HELP(SHOW OSPF STATE, [all] [<name>], [[Show information about OSPF network state]])
-CF_CLI(SHOW OSPF STATE, optsym opttext, [<name>], [[Show information about reachable OSPF network state]])
+CF_CLI(SHOW OSPF STATE, optproto opttext, [<name>], [[Show information about reachable OSPF network state]])
{ ospf_sh_state(proto_get_named($4, &proto_ospf), 1, 1); };
-CF_CLI(SHOW OSPF STATE ALL, optsym opttext, [<name>], [[Show information about all OSPF network state]])
+CF_CLI(SHOW OSPF STATE ALL, optproto opttext, [<name>], [[Show information about all OSPF network state]])
{ ospf_sh_state(proto_get_named($5, &proto_ospf), 1, 0); };
CF_CLI_HELP(SHOW OSPF LSADB, ..., [[Show content of OSPF LSA database]]);
@@ -544,7 +544,7 @@ lsadb_args:
| lsadb_args LSID idval { $$ = $1; $$->lsid = $3; }
| lsadb_args SELF { $$ = $1; $$->router = SH_ROUTER_SELF; }
| lsadb_args ROUTER idval { $$ = $1; $$->router = $3; }
- | lsadb_args SYM { $$ = $1; $$->name = $2; }
+ | lsadb_args CF_SYM_PROTO { $$ = $1; $$->proto = (struct ospf_proto *) proto_get_named($2, &proto_ospf); }
;
CF_CODE
diff --git a/proto/ospf/ospf.c b/proto/ospf/ospf.c
index ef2a0df4..816f33aa 100644
--- a/proto/ospf/ospf.c
+++ b/proto/ospf/ospf.c
@@ -1402,7 +1402,7 @@ lsa_compare_for_lsadb(const void *p1, const void *p2)
void
ospf_sh_lsadb(struct lsadb_show_data *ld)
{
- struct ospf_proto *p = (struct ospf_proto *) proto_get_named(ld->name, &proto_ospf);
+ struct ospf_proto *p = ld->proto;
uint num = p->gr->hash_entries;
uint i, j;
int last_dscope = -1;
diff --git a/proto/ospf/ospf.h b/proto/ospf/ospf.h
index 7fac47c8..82ae4df4 100644
--- a/proto/ospf/ospf.h
+++ b/proto/ospf/ospf.h
@@ -900,7 +900,7 @@ struct ospf_lsreq_header
#define SH_ROUTER_SELF 0xffffffff
struct lsadb_show_data {
- struct symbol *name; /* Protocol to request data from */
+ struct ospf_proto *proto; /* Protocol to request data from */
u16 type; /* LSA Type, 0 -> all */
u16 scope; /* Scope, 0 -> all, hack to handle link scope as 1 */
u32 area; /* Specified for area scope */