BUG? in find_vma function (2.2.0 mm/mmap.c)

s-sumi@trc.rwcp.or.jp
Wed, 27 Jan 1999 14:05:23 +0900


Hi,

I found a bug (maybe) in find_vma function (2.2.0 mm/mmap.c).
In original code, find_vma may return mm->mmap_cache directly in wrong case.

Here is patch.
====================
*** linux/mm/mmap.c.org Tue Jan 19 09:24:06 1999
--- linux/mm/mmap.c Wed Jan 27 10:30:42 1999
***************
*** 393,398 ****
--- 393,400 ----
} else {
/* Then go through the AVL tree quickly. */
struct vm_area_struct * tree = mm->mmap_avl;
+
+ vma = NULL;
for (;;) {
if (tree == vm_avl_empty)
break;
====================
-----
Shinji Sumimoto E-Mail: s-sumi@trc.rwcp.or.jp
Real World Computing Partnership

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/