33 lines
1.1 KiB
Diff
33 lines
1.1 KiB
Diff
From bc2fec292417407a84b9c68b7b360236bb8120a8 Mon Sep 17 00:00:00 2001
|
|
From: Jens Osterkamp <jens@linux.vnet.ibm.com>
|
|
Date: Sun, 6 Mar 2011 21:38:42 -0800
|
|
Subject: [PATCH 19/51] fix memory leak in vdp_indicate
|
|
|
|
In function vdp_indicate, if (vd->role == VDP_ROLE_STATION) is true and
|
|
(vdp_profile_equal(p, profile)) is true, then pointer profile will leak.
|
|
This fixes it.
|
|
|
|
Reported-by: bluewindow <bluewindow@h3c.com>
|
|
Signed-off-by: Jens Osterkamp <jens@linux.vnet.ibm.com>
|
|
Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
|
|
Signed-off-by: Petr Sabata <psabata@redhat.com>
|
|
---
|
|
lldp_vdp.c | 1 +
|
|
1 files changed, 1 insertions(+), 0 deletions(-)
|
|
|
|
diff --git a/lldp_vdp.c b/lldp_vdp.c
|
|
index efe9f64..b0855bd 100644
|
|
--- a/lldp_vdp.c
|
|
+++ b/lldp_vdp.c
|
|
@@ -892,6 +892,7 @@ int vdp_indicate(struct vdp_data *vd, struct unpacked_tlv *tlv, int ecp_mode)
|
|
vsi_responses[p->response],
|
|
p->response, p->instance[15],
|
|
vsi_states[p->state]);
|
|
+ free(profile);
|
|
} else {
|
|
LLDPAD_DBG("%s(%i): station: profile not found !\n",
|
|
__func__, __LINE__);
|
|
--
|
|
1.7.4.4
|
|
|