mirror of
https://github.com/SCST-project/scst.git
synced 2026-05-22 21:21:28 +00:00
isert: Fix page leak if alloc_page fails
Signed-off-by: Yan Burman <yanb@mellanox.com> git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/iser@5871 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -85,7 +85,7 @@ static int isert_buf_alloc_pg(struct ib_device *ib_dev,
|
||||
goto out;
|
||||
|
||||
out_map_failed:
|
||||
for (; i > 0; --i)
|
||||
for (; i >= 0; --i)
|
||||
__free_page(sg_page(&isert_buf->sg[i]));
|
||||
kfree(isert_buf->sg);
|
||||
isert_buf->sg = NULL;
|
||||
|
||||
Reference in New Issue
Block a user