alloc/aligned/foreign: actually correct the allocated address

This commit is contained in:
Danny Robson 2018-12-19 17:34:47 +11:00
parent 39ed7b27e8
commit 6308166179

View File

@ -70,7 +70,8 @@ namespace cruft::alloc::raw::aligned {
cruft::view<u08*>
allocate (std::size_t bytes)
{
return m_successor.allocate (bytes);
auto res = m_successor.allocate (bytes);
return { res.begin () + m_offset, bytes };
}