I’ve recently come across arena allocator, and I can already see how they are a big improvement to the standard heap allocator present in C.

What are the other areas it fails to address, when it comes to memory safety?

  • @CameronDev@programming.dev
    link
    fedilink
    31 month ago

    Is this homework?

    One possible example I can think of, is if there is a struct of a known size, and you want to find it, you can allocate a block of the same size, and get a ptr that is near it?

    Also, if you know of a function vulnerable to buffer overruns, you can place data near the input for a given buffer as long as you know its size and therefore control what the vulnerable function reads.,