3 ms·
Proper input validation is really hard, and a reliable crash on incorrect input is frankly much better than other alternatives such as soldiering on and output
by SiempreViernes 7y ago
Proper input validation is really hard, and a reliable crash on incorrect input is frankly much better than other alternatives such as soldiering on and output trash, or even worse seemingly fine results.
Of course, it sucks if it takes a few hours before you get your crash, that usually tricks you into thinking the software did something wrong and not you. Best is if it dies immediately upon reading the input, and if it does that with an error or a crash isn't crucial, though of course getting a clear error message is always better.
As a comparison, a collaboration internal tool I need to use will print a helpful usage message, and then segfault if you call it without any arguments...