Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 1254
b: refs/heads/master
c: 49a4387
h: refs/heads/master
v: v3
  • Loading branch information
Linus Torvalds authored and Linus Torvalds committed May 19, 2005
1 parent 5bd4da5 commit 42c7a05
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 05d3794aa8bd3b2c9f7920a05003c331cdeb75c5
refs/heads/master: 49a43876b935c811cfd29d8fe998a6912a1cc5c4
4 changes: 2 additions & 2 deletions trunk/mm/mmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -1244,7 +1244,7 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0,
addr = mm->free_area_cache;

/* make sure it can fit in the remaining address space */
if (addr >= len) {
if (addr > len) {
vma = find_vma(mm, addr-len);
if (!vma || addr <= vma->vm_start)
/* remember the address as a hint for next time */
Expand All @@ -1266,7 +1266,7 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0,

/* try just below the current vma->vm_start */
addr = vma->vm_start-len;
} while (len <= vma->vm_start);
} while (len < vma->vm_start);

/*
* A failed mmap() very likely causes application failure,
Expand Down

0 comments on commit 42c7a05

Please sign in to comment.