diff options
author | David Lamparter <equinox@diac24.net> | 2012-04-20 17:23:39 +0200 |
---|---|---|
committer | David Lamparter <equinox@diac24.net> | 2012-04-20 17:29:31 +0200 |
commit | 9665856e3718e42068e7d897f5e2468e77fb8c17 (patch) | |
tree | 264cd6e05ee23bcf46d1ce42c38ffa228b5035f1 /zebra/zserv.c | |
parent | fa4094ac49b4cc23589f5c5b7e608c4b4ee6ca04 (diff) |
Revert "zebra: clean up client routes when client goes away"
This reverts commit af56d404cd56d94ad3b2ec3f159650eb72baef0a,
which was accidentally duplicating functionality from commit
2ea1ab1 "zebra: ZEBRA_HELLO and mopping up routes (BZ#448)"
Conflicts:
zebra/zebra_rib.c
Signed-off-by: David Lamparter <equinox@diac24.net>
Diffstat (limited to 'zebra/zserv.c')
-rw-r--r-- | zebra/zserv.c | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/zebra/zserv.c b/zebra/zserv.c index b1f539d3..09152170 100644 --- a/zebra/zserv.c +++ b/zebra/zserv.c @@ -741,13 +741,6 @@ zread_ipv4_add (struct zserv *client, u_short length) /* Type, flags, message. */ rib->type = stream_getc (s); - /* Update client's route type if it is not done yet. */ - /* It is done here since only zread_ipv4/6_add() and - * zread_ipv4/6_delete() decode Zebra messages and retrieve - * route types. */ - if (client->route_type == ZEBRA_ROUTE_MAX) - client->route_type = rib->type; - rib->flags = stream_getc (s); message = stream_getc (s); safi = stream_getw (s); @@ -924,11 +917,6 @@ zread_ipv6_add (struct zserv *client, u_short length) /* Type, flags, message. */ api.type = stream_getc (s); - /* Update the route type of the client. - * Same as in zread_ipv4_add(). */ - if (client->route_type == ZEBRA_ROUTE_MAX) - client->route_type = api.type; - api.flags = stream_getc (s); api.message = stream_getc (s); api.safi = stream_getw (s); @@ -1127,14 +1115,6 @@ zebra_score_rib (int client_sock) static void zebra_client_close (struct zserv *client) { - struct stream *s; - - /* Sweep all routes learned from the client first. */ - rib_sweep_client_route(client); - /* Reset the route type. It may not be necessary since the - * whole client will be freed. */ - client->route_type = ZEBRA_ROUTE_MAX; - /* Close file descriptor. */ if (client->sock) { @@ -1174,9 +1154,6 @@ zebra_client_create (int sock) /* Make client input/output buffer. */ client->sock = sock; - /* Set the default route type to ZEBRA_ROUTE_MAX; it will be updated - * once new routes are received. */ - client->route_type = ZEBRA_ROUTE_MAX; client->ibuf = stream_new (ZEBRA_MAX_PACKET_SIZ); client->obuf = stream_new (ZEBRA_MAX_PACKET_SIZ); client->wb = buffer_new(0); |