diff options
author | paul <paul> | 2006-08-04 06:18:04 +0000 |
---|---|---|
committer | paul <paul> | 2006-08-04 06:18:04 +0000 |
commit | 116008fe8eab1c67ab91d1851a659cc9e77d2f6d (patch) | |
tree | 0c338fdbaa0f395a4c2337d9df0f310dfbd04c43 /zebra/irdp_main.c | |
parent | 88c2da7a4e865a2859a93b206be4690dda4da4a4 (diff) | |
download | quagga-116008fe8eab1c67ab91d1851a659cc9e77d2f6d.tar.bz2 quagga-116008fe8eab1c67ab91d1851a659cc9e77d2f6d.tar.xz |
[zebra] IRDP: Move stream_free to where its created, probably fixing a leak
2006-08-01 Paul Jakma <paul.jakma@sun.com>
* irdp_main.c: (irdp_advertisement) free the stream here, when done,
right under where it was allocated so it's blindingly obvious
it's correct. This possibly fixes a very slow leak of streams in
zebra.
* irdp_packet.c: (send_packet) don't free the stream here as
it's hard to tell if right, plus an error case seemed to
returning before free anyway.
Diffstat (limited to 'zebra/irdp_main.c')
-rw-r--r-- | zebra/irdp_main.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/zebra/irdp_main.c b/zebra/irdp_main.c index 04f12f18..e4e71cf3 100644 --- a/zebra/irdp_main.c +++ b/zebra/irdp_main.c @@ -224,7 +224,8 @@ static void irdp_advertisement (struct interface *ifp, struct prefix *p) struct stream *s; s = stream_new (128); make_advertisement_packet (ifp, p, s); - irdp_send(ifp, p, s); + irdp_send(ifp, p, s); + stream_free (s); } int irdp_send_thread(struct thread *t_advert) |