Commit 8e680b66 authored by Andrew Morton's avatar Andrew Morton Committed by Ben Collins

[PATCH] initialise vma->vm_next in do_mmap_pgoff()

We end up inspecting this field in zap_page_range(), on the mmap error path.
Best initialise it to something...
parent a7faa309
...@@ -677,6 +677,7 @@ unsigned long do_mmap_pgoff(struct file * file, unsigned long addr, ...@@ -677,6 +677,7 @@ unsigned long do_mmap_pgoff(struct file * file, unsigned long addr,
vma->vm_pgoff = pgoff; vma->vm_pgoff = pgoff;
vma->vm_file = NULL; vma->vm_file = NULL;
vma->vm_private_data = NULL; vma->vm_private_data = NULL;
vma->vm_next = NULL;
INIT_LIST_HEAD(&vma->shared); INIT_LIST_HEAD(&vma->shared);
if (file) { if (file) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment