lkml.org 
[lkml]   [2014]   [Aug]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] ipc/shm: fix the historical/wrong mm->start_stack check
On Mon, Aug 25, 2014 at 09:12:07PM +0200, Oleg Nesterov wrote:
> + vma = find_vma(current->mm, addr);
> + if (vma) {
> + unsigned long end = addr + size;
> +
> + if (vma->vm_flags & VM_GROWSDOWN)
> + end += PAGE_SIZE * 5;
> +
> + if (end < addr || end > vma->vm_start)
> + goto invalid;

Looks good to me, but I somehow missed in first version of the patch
too the following aspect -- end > vma->vm_start? Maybe end >= vma->vm_end?


\
 
 \ /
  Last update: 2014-08-25 23:41    [W:0.164 / U:0.936 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site