Skip to content

Commit

Permalink
[XFS] Fix double free in xfs_buf_get_noaddr error handling path
Browse files Browse the repository at this point in the history
SGI-PV: 964983
SGI-Modid: xfs-linux-melb:xfs-kern:28639a

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: David Chinner <dgc@sgi.com>
Signed-off-by: Tim Shimmin <tes@sgi.com>
  • Loading branch information
Christoph Hellwig authored and Tim Shimmin committed Jul 14, 2007
1 parent 3db296f commit ca165b8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fs/xfs/linux-2.6/xfs_buf.c
Original file line number Diff line number Diff line change
Expand Up @@ -792,8 +792,9 @@ xfs_buf_get_noaddr(
fail_free_mem:
while (--i >= 0)
__free_page(bp->b_pages[i]);
_xfs_buf_free_pages(bp);
fail_free_buf:
xfs_buf_free(bp);
xfs_buf_deallocate(bp);
fail:
return NULL;
}
Expand Down

0 comments on commit ca165b8

Please sign in to comment.