diff options
Diffstat (limited to 'src/tool_operate.c')
-rw-r--r-- | src/tool_operate.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/tool_operate.c b/src/tool_operate.c index 37ff44795..2e576d0d0 100644 --- a/src/tool_operate.c +++ b/src/tool_operate.c @@ -595,6 +595,10 @@ static CURLcode post_per_transfer(struct GlobalConfig *global, if(global->showerror) fprintf(global->errors, "curl: (%d) Failed writing body\n", result); } + if(result && config->rm_partial) { + notef(global, "Removing output file: %s", per->outfile); + unlink(per->outfile); + } } /* File time can only be set _after_ the file has been closed */ |