public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 10/11] iscsi bugfixes: fix mem leaks in libiscsi
@ 2006-07-24 20:47 Mike Christie
  0 siblings, 0 replies; only message in thread
From: Mike Christie @ 2006-07-24 20:47 UTC (permalink / raw)
  To: linux-scsi

We were leaking some strings. This patch just frees them.

Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>

diff --git a/drivers/scsi/libiscsi.c b/drivers/scsi/libiscsi.c
index c628c63..5884cd2 100644
--- a/drivers/scsi/libiscsi.c
+++ b/drivers/scsi/libiscsi.c
@@ -1357,6 +1357,8 @@ void iscsi_session_teardown(struct iscsi
 	iscsi_pool_free(&session->mgmtpool, (void**)session->mgmt_cmds);
 	iscsi_pool_free(&session->cmdpool, (void**)session->cmds);
 
+	kfree(session->targetname);
+
 	iscsi_destroy_session(cls_session);
 	scsi_host_put(shost);
 	module_put(owner);
@@ -1491,6 +1493,7 @@ void iscsi_conn_teardown(struct iscsi_cl
 
 	spin_lock_bh(&session->lock);
 	kfree(conn->data);
+	kfree(conn->persistent_address);
 	__kfifo_put(session->mgmtpool.queue, (void*)&conn->login_mtask,
 		    sizeof(void*));
 	list_del(&conn->item);



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2006-07-24 20:51 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-24 20:47 [PATCH 10/11] iscsi bugfixes: fix mem leaks in libiscsi Mike Christie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox