Timeline for Should one check for every little error in C?
Current License: CC BY-SA 3.0
9 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| May 23, 2017 at 12:40 | history | edited | Community Bot |
replaced http://stackoverflow.com/ with https://stackoverflow.com/
|
|
| Nov 17, 2015 at 16:39 | comment | added | Ben S |
Whatever you do, don't just carry on running as though nothing's happened! If the command dump_database > backups/db_dump.txt fails to write to standard output at any given point, I wouldn't want it to carry on and exit successfully. (Not that databases are backed up that way, but the point still stands)
|
|
| Nov 17, 2015 at 16:03 | comment | added | John Marshall | @JAB: You might exit with EX_IOERR or so, if that was appropriate. | |
| Nov 17, 2015 at 15:49 | comment | added | TripeHound |
@JAB You send a message to stdout ... obvious :-)
|
|
| Nov 17, 2015 at 15:33 | vote | accept | Derek 朕會功夫 | ||
| Nov 17, 2015 at 13:21 | comment | added | JAB | @Damien_The_Unbeliever What do you do when writing to stderr fails? | |
| Nov 17, 2015 at 11:18 | comment | added | Davor Ždralo |
@Damien_The_Unbeliever - especially since stdout can be redirected to a file, or not even exist depending on the system. stdout is not a "write to console" stream, it's usually that, but it doesn't have to be.
|
|
| Nov 17, 2015 at 8:23 | comment | added | Damien_The_Unbeliever | Sorry, minor nit to pick here - "writing to standard output will not fail. If it does fail, how would you tell the user, anyway?" - by writing to standard error? There's no guarantee that a failure to write to one implies that it's impossible to write to the other. | |
| Nov 17, 2015 at 1:22 | history | answered | user22815 | CC BY-SA 3.0 |