patch-1.3.28 linux/mm/kmalloc.c

Next file: linux/mm/swap.c
Previous file: linux/kernel/time.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.27/linux/mm/kmalloc.c linux/mm/kmalloc.c
@@ -87,7 +87,7 @@
 };
 
 /*
- * For now it is unsafe to allocate bucket sizes between n & n=16 where n is
+ * For now it is unsafe to allocate bucket sizes between n and n-16 where n is
  * 4096 * any power of two
  */
 #if PAGE_SIZE == 4096
@@ -293,7 +293,7 @@
 	}
 
 	if ((order < 0) ||
-	    (order > sizeof(sizes) / sizeof(sizes[0])) ||
+	    (order >= sizeof(sizes) / sizeof(sizes[0])) ||
 	    (((long) (page->next)) & ~PAGE_MASK) ||
 	    (p->bh_flags != MF_USED)) {
 		printk("kfree of non-kmalloced memory: %p, next= %p, order=%d\n",

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this