Restore the old semantics of deleting the output file when interrupted.
Some people liked this and some didn't, so POLA won.
This commit is contained in:
parent
fa0c86aadc
commit
9516ffa7c0
@ -400,10 +400,12 @@ fetch(char *URL, char *path)
|
||||
signal:
|
||||
if (sigalrm)
|
||||
warnx("transfer timed out");
|
||||
if (sigint)
|
||||
if (sigint) {
|
||||
warnx("transfer interrupted");
|
||||
goto failure;
|
||||
}
|
||||
|
||||
if (!sigalrm && !sigint) {
|
||||
if (!sigalrm) {
|
||||
/* check the status of our files */
|
||||
if (ferror(f))
|
||||
warn("%s", URL);
|
||||
|
Loading…
Reference in New Issue
Block a user