diff options
author | paul <paul> | 2006-01-19 20:16:55 +0000 |
---|---|---|
committer | paul <paul> | 2006-01-19 20:16:55 +0000 |
commit | e8e1946edf6ba87ef53832cdceccc39d7f0c3f26 (patch) | |
tree | fcdaf92bf4129a8a58825bd21ae841a6b3b2bda8 /zebra | |
parent | 779adb0147cfff1a831b08853976342ad2110fcd (diff) |
[compiler] miscellaneous trivial compiler warning fixes
2006-01-19 Paul Jakma <paul.jakma@sun.com>
* (general) various miscellaneous compiler warning fixes.
Remove redundant break statements from switch clauses
which return.
return from main, not exit, cause it annoys SOS.
Remove stray semi-colons which cause empty-statement
warnings.
* zebra/main.c: (sighup) remove private declaration of external
function.
Diffstat (limited to 'zebra')
-rw-r--r-- | zebra/ChangeLog | 11 | ||||
-rw-r--r-- | zebra/main.c | 5 | ||||
-rw-r--r-- | zebra/zebra_rib.c | 4 | ||||
-rw-r--r-- | zebra/zserv.c | 1 |
4 files changed, 14 insertions, 7 deletions
diff --git a/zebra/ChangeLog b/zebra/ChangeLog index b33180f7..b40f78fb 100644 --- a/zebra/ChangeLog +++ b/zebra/ChangeLog @@ -1,3 +1,14 @@ +2006-01-19 Paul Jakma <paul.jakma@sun.com> + + * (general) various miscellaneous compiler warning fixes. + Remove redundant break statements from switch clauses + which return. + Remove stray semi-colons which cause empty-statement + warnings. + * main.c: (sighup) remove private declaration of external + function. + (main) return from main, not exit, cause it annoys SOS. + 2006-01-18 Gunnar Stigen <gunnar.stigen@axxessit.no> * zebra_rib.c: Take interface metric into account. diff --git a/zebra/main.c b/zebra/main.c index 67108c4e..dbe1b537 100644 --- a/zebra/main.c +++ b/zebra/main.c @@ -163,9 +163,6 @@ sighup (void) static void sigint (void) { - /* Decrared in rib.c */ - void rib_close (); - zlog_notice ("Terminating on signal"); if (!retain_mode) @@ -378,5 +375,5 @@ main (int argc, char **argv) thread_call (&thread); /* Not reached... */ - exit (0); + return 0; } diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c index 5d9cb2f6..a591776a 100644 --- a/zebra/zebra_rib.c +++ b/zebra/zebra_rib.c @@ -1497,7 +1497,7 @@ static_ipv4_nexthop_same (struct nexthop *nexthop, struct static_ipv4 *si) if (nexthop->type == NEXTHOP_TYPE_BLACKHOLE && si->type == STATIC_IPV4_BLACKHOLE) return 1; - return 0;; + return 0; } /* Uninstall static route from RIB. */ @@ -2045,7 +2045,7 @@ static_ipv6_nexthop_same (struct nexthop *nexthop, struct static_ipv6 *si) && IPV6_ADDR_SAME (&nexthop->gate.ipv6, &si->ipv6) && strcmp (nexthop->ifname, si->ifname) == 0) return 1; - return 0;; + return 0; } static void diff --git a/zebra/zserv.c b/zebra/zserv.c index f8bfcfaa..aa88ab5d 100644 --- a/zebra/zserv.c +++ b/zebra/zserv.c @@ -138,7 +138,6 @@ zebra_server_send_message(struct zserv *client) client->t_suicide = thread_add_event(zebrad.master, zserv_delayed_close, client, 0); return -1; - break; case BUFFER_EMPTY: THREAD_OFF(client->t_write); break; |