]> err.no Git - linux-2.6/commit
[PATCH] Fix strange size check in __get_vm_area_node()
authorOGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Thu, 16 Nov 2006 09:19:29 +0000 (01:19 -0800)
committerLinus Torvalds <torvalds@woody.osdl.org>
Thu, 16 Nov 2006 19:43:38 +0000 (11:43 -0800)
commit31be8309532a6743f301cb2e83bd12ca07988b09
tree9f84911bae39b11247f2e62ed9d7d451ef4b0a2f
parentda63fc7ce63b43426dc3c69c05e28de2872c159a
[PATCH] Fix strange size check in __get_vm_area_node()

Recently, __get_vm_area_node() was changed like following

  if (unlikely(!area))
  return NULL;

- if (unlikely(!size)) {
- kfree (area);
+ if (unlikely(!size))
  return NULL;
- }

It is leaking `area', also original code seems strange already.
Probably, we wanted to do this patch.

Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
mm/vmalloc.c