slab: fix typo in allocation failure handling
This patch fixes wrong array index in allocation failure handling. Cc: Pekka Enberg <penberg@cs.helsinki.fi> Acked-by: Christoph Lameter <clameter@sgi.com> Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Родитель
e9b5a495dc
Коммит
cc550defe9
|
@ -1043,7 +1043,7 @@ static struct array_cache **alloc_alien_cache(int node, int limit)
|
|||
}
|
||||
ac_ptr[i] = alloc_arraycache(node, limit, 0xbaadf00d);
|
||||
if (!ac_ptr[i]) {
|
||||
for (i--; i <= 0; i--)
|
||||
for (i--; i >= 0; i--)
|
||||
kfree(ac_ptr[i]);
|
||||
kfree(ac_ptr);
|
||||
return NULL;
|
||||
|
|
Загрузка…
Ссылка в новой задаче