Re: [PATCH] iscsi: fix leak of session->initiator_alias
FUJITA Tomonori <[email protected]>
| Newsgroups | org.kernel.vger.stgt |
|---|---|
| Message-ID | <[email protected]> |
On Fri, 21 Feb 2014 22:15:02 +0900 Ryusuke Konishi <[email protected]> wrote: > session->initiator_alias is not freed in error paths of > session_create() and even in the normal path of session_destroy(). > > This fixes these leak bugs. > > Note that we don't have to do a null check for > session->initiator_alias before calling free(session->initiator_alias) > because free() function simply ignores NULL pointer. > > Signed-off-by: Ryusuke Konishi <[email protected]> > --- > usr/iscsi/session.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) Applied, thanks a lot!