diff options
author | Pierre-Yves Ritschard <pyr@cvs.openbsd.org> | 2009-06-05 21:19:12 +0000 |
---|---|---|
committer | Pierre-Yves Ritschard <pyr@cvs.openbsd.org> | 2009-06-05 21:19:12 +0000 |
commit | ea0934a92c8a65d1f7b4398f101ef322c412cf02 (patch) | |
tree | 864db7ad071d72e78c41c5b4383405cdf1a2c76b /usr.sbin | |
parent | 0bc023d5d841447af472a603455d0282221dc7f0 (diff) |
forgot to commit the ospfctl bits, this unbreaks the tree.
noticed by michele@
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/ospfctl/ospfctl.c | 47 |
1 files changed, 20 insertions, 27 deletions
diff --git a/usr.sbin/ospfctl/ospfctl.c b/usr.sbin/ospfctl/ospfctl.c index dbfdbb386f8..9af336ba8b0 100644 --- a/usr.sbin/ospfctl/ospfctl.c +++ b/usr.sbin/ospfctl/ospfctl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ospfctl.c,v 1.46 2009/04/07 14:57:33 reyk Exp $ */ +/* $OpenBSD: ospfctl.c,v 1.47 2009/06/05 21:19:11 pyr Exp $ */ /* * Copyright (c) 2005 Claudio Jeker <claudio@openbsd.org> @@ -81,13 +81,6 @@ usage(void) exit(1); } -/* dummy function so that ospfctl does not need libevent */ -void -imsg_event_add(struct imsgbuf *i) -{ - /* nothing */ -} - int main(int argc, char *argv[]) { @@ -142,7 +135,7 @@ main(int argc, char *argv[]) /* not reached */ case SHOW: case SHOW_SUM: - imsg_compose(ibuf, IMSG_CTL_SHOW_SUM, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_SUM, 0, 0, -1, NULL, 0); break; case SHOW_IFACE: printf("%-11s %-18s %-6s %-10s %-10s %-8s %3s %3s\n", @@ -155,7 +148,7 @@ main(int argc, char *argv[]) if (ifidx == 0) errx(1, "no such interface %s", res->ifname); } - imsg_compose(ibuf, IMSG_CTL_SHOW_INTERFACE, 0, 0, + imsg_compose(ibuf, IMSG_CTL_SHOW_INTERFACE, 0, 0, -1, &ifidx, sizeof(ifidx)); break; case SHOW_NBR: @@ -163,72 +156,72 @@ main(int argc, char *argv[]) "State", "DeadTime", "Address", "Iface","Uptime"); /*FALLTHROUGH*/ case SHOW_NBR_DTAIL: - imsg_compose(ibuf, IMSG_CTL_SHOW_NBR, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_NBR, 0, 0, -1, NULL, 0); break; case SHOW_DB: - imsg_compose(ibuf, IMSG_CTL_SHOW_DATABASE, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_DATABASE, 0, 0, -1, NULL, 0); break; case SHOW_DBBYAREA: - imsg_compose(ibuf, IMSG_CTL_SHOW_DATABASE, 0, 0, + imsg_compose(ibuf, IMSG_CTL_SHOW_DATABASE, 0, 0, -1, &res->addr, sizeof(res->addr)); break; case SHOW_DBEXT: - imsg_compose(ibuf, IMSG_CTL_SHOW_DB_EXT, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_DB_EXT, 0, 0, -1, NULL, 0); break; case SHOW_DBNET: - imsg_compose(ibuf, IMSG_CTL_SHOW_DB_NET, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_DB_NET, 0, 0, -1, NULL, 0); break; case SHOW_DBRTR: - imsg_compose(ibuf, IMSG_CTL_SHOW_DB_RTR, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_DB_RTR, 0, 0, -1, NULL, 0); break; case SHOW_DBSELF: - imsg_compose(ibuf, IMSG_CTL_SHOW_DB_SELF, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_DB_SELF, 0, 0, -1, NULL, 0); break; case SHOW_DBSUM: - imsg_compose(ibuf, IMSG_CTL_SHOW_DB_SUM, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_DB_SUM, 0, 0, -1, NULL, 0); break; case SHOW_DBASBR: - imsg_compose(ibuf, IMSG_CTL_SHOW_DB_ASBR, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_DB_ASBR, 0, 0, -1, NULL, 0); break; case SHOW_RIB: printf("%-20s %-17s %-12s %-9s %-7s %-8s\n", "Destination", "Nexthop", "Path Type", "Type", "Cost", "Uptime"); /*FALLTHROUGH*/ case SHOW_RIB_DTAIL: - imsg_compose(ibuf, IMSG_CTL_SHOW_RIB, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_SHOW_RIB, 0, 0, -1, NULL, 0); break; case SHOW_FIB: if (!res->addr.s_addr) - imsg_compose(ibuf, IMSG_CTL_KROUTE, 0, 0, + imsg_compose(ibuf, IMSG_CTL_KROUTE, 0, 0, -1, &res->flags, sizeof(res->flags)); else - imsg_compose(ibuf, IMSG_CTL_KROUTE_ADDR, 0, 0, + imsg_compose(ibuf, IMSG_CTL_KROUTE_ADDR, 0, 0, -1, &res->addr, sizeof(res->addr)); show_fib_head(); break; case SHOW_FIB_IFACE: if (*res->ifname) - imsg_compose(ibuf, IMSG_CTL_IFINFO, 0, 0, + imsg_compose(ibuf, IMSG_CTL_IFINFO, 0, 0, -1, res->ifname, sizeof(res->ifname)); else - imsg_compose(ibuf, IMSG_CTL_IFINFO, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_IFINFO, 0, 0, -1, NULL, 0); show_interface_head(); break; case FIB: errx(1, "fib couple|decouple"); break; case FIB_COUPLE: - imsg_compose(ibuf, IMSG_CTL_FIB_COUPLE, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_FIB_COUPLE, 0, 0, -1, NULL, 0); printf("couple request sent.\n"); done = 1; break; case FIB_DECOUPLE: - imsg_compose(ibuf, IMSG_CTL_FIB_DECOUPLE, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_FIB_DECOUPLE, 0, 0, -1, NULL, 0); printf("decouple request sent.\n"); done = 1; break; case RELOAD: - imsg_compose(ibuf, IMSG_CTL_RELOAD, 0, 0, NULL, 0); + imsg_compose(ibuf, IMSG_CTL_RELOAD, 0, 0, -1, NULL, 0); printf("reload request sent.\n"); done = 1; break; |