Hacker News new | ask | show | jobs
by bvinc 2108 days ago
> As a C programmer I would say they are my favorite class of bugs, because they are so easy to fix,

I know what you're trying to say, because at least 95% of segmentation faults are easy to fix, but I take issue with this. The hardest bug that I've ever fixed was a segmentation fault!

You've obviously never experienced random crashes where the best idea anyone has is to bisect code changes in production and see when the crashes stop.

And you've obviously never experienced random crashes on customer machines where you've tested the crashing function for weeks, poured over crash dumps and ran the exact same function with the exact same data and could never reproduce it.

1 comments

I think you're leaving out the option that the person you're replying to has seen even worse bugs because they have better ideas of how to deal with random crashes than bisecting code changes. For example, with the details you provided (of which there isn't much) I would suspect a thread safety issue.
Thank you! I find that the worst bugs are usually the ones involving the logic of the algorithm, and the language has nothing to do with the bug itself. This is why I think that a language that is very explicit, and without side effects and therefor easy to step though using a debugger is desirable.

Buffer over runs, can be trickier, but I have plenty of tooling to find the issues.

Thread safety issues are what nightmares are made of.