this post was submitted on 31 Aug 2025
314 points (96.4% liked)

Programmer Humor

26095 readers
1424 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS
 

Finally I have a valid reason to learn about memory management. It was also hella weird when encountering it.

you are viewing a single comment's thread
view the rest of the comments
[–] diemartin@sh.itjust.works 4 points 23 hours ago

It'll be fun when you get to funny errors because you used freed memory.

When I was learning about linked lists and decided to use them in a project, I "removed" items by making the previous item's next point to this item's next, except I misplaced a call to free before using the fields, and it somehow still worked most of the time on debug builds, but on optimized builds it would cause a segmentation fault 100% of the time.