summaryrefslogtreecommitdiffstats
path: root/mm/page_alloc.c
diff options
context:
space:
mode:
authorJulia Lawall <julia@diku.dk>2010-03-11 00:20:42 +0100
committerLinus Torvalds <torvalds@linux-foundation.org>2010-03-13 00:52:28 +0100
commit9b3a6549b2602ca30f58715a0071e29f9898cae9 (patch)
tree8709822f0018f55a7e542ca9c0755d99f5226b4f /mm/page_alloc.c
parentmm: do not iterate over NR_CPUS in __zone_pcp_update() (diff)
downloadlinux-9b3a6549b2602ca30f58715a0071e29f9898cae9.tar.xz
linux-9b3a6549b2602ca30f58715a0071e29f9898cae9.zip
drivers/scsi/ses.c: eliminate double free
The few lines below the kfree of hdr_buf may go to the label err_free which will also free hdr_buf. The most straightforward solution seems to be to just move the kfree of hdr_buf after these gotos. A simplified version of the semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @r@ identifier E; expression E1; iterator I; statement S; @@ *kfree(E); ... when != E = E1 when != I(E,...) S when != &E *kfree(E); // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Cc: James Bottomley <James.Bottomley@HansenPartnership.com> Cc: <stable@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions