buffer: fix abort while passing incorrect this in slice