C meme

Gregor@gregtech.eu to Programmer Humor@programming.dev – 205 points –

A screenshot from youtube, Virbox

18

Eh... ship it. RAM is cheap.

"Uh, Boss, our customers are sending us the invoices for their RAM purchases."

That's why I preallocate the max memory I will need just like I was taught to do in Fortran. You can't leak what you don't have.

Heap allocation failure > gradual memory leak

Checkmate atheists.

This is why I only allocate on the stack

People who are enthusiastic about using pointers in C++ are doing it wrong. Never use a pointer when you can get away with a reference.

For C++, yes. But "reference" is just a way of using the pointer when it comes to C

The line causing the memory leaks is actually the lack of a line: free().