projects
/
project
/
uclient.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c35d9db
)
uclient-fetch: truncate output files (unless resuming)
author
Felix Fietkau
<nbd@openwrt.org>
Sat, 23 Jan 2016 19:59:45 +0000
(20:59 +0100)
committer
Felix Fietkau
<nbd@openwrt.org>
Sat, 23 Jan 2016 19:59:45 +0000
(20:59 +0100)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
uclient-fetch.c
patch
|
blob
|
history
diff --git
a/uclient-fetch.c
b/uclient-fetch.c
index ebf49ae559ac395fbd069ab53c3d1e29da42f4be..851994f47b841668ca066a294e9268afff07a123 100644
(file)
--- a/
uclient-fetch.c
+++ b/
uclient-fetch.c
@@
-103,7
+103,7
@@
static int open_output_file(const char *path, uint64_t resume_offset)
if (cur_resume)
flags = O_RDWR;
else
- flags = O_WRONLY;
+ flags = O_WRONLY
| O_TRUNC
;
if (!cur_resume && !output_file)
flags |= O_EXCL;