Message ID | 87oa6aysje.fsf@@concordia.ellerman.id.au (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
diff --git a/mm/slub.c b/mm/slub.c index 0c8ace04f075..66191ea4545a 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -3630,6 +3630,9 @@ const char *__check_heap_object(const void *ptr, unsigned long n, /* Find object. */ s = page->slab_cache; + /* Subtract red zone if enabled */ + ptr = restore_red_left(s, ptr); + /* Find offset within object. */ offset = (ptr - page_address(page)) % s->size;