summaryrefslogtreecommitdiff
path: root/firmware/common
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/common')
-rw-r--r--firmware/common/file.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/firmware/common/file.c b/firmware/common/file.c
index 177635d0be..504273fd67 100644
--- a/firmware/common/file.c
+++ b/firmware/common/file.c
@@ -54,7 +54,7 @@ static int flush_cache(int fd);
int creat(const char *pathname, int mode)
{
(void)mode;
- return open(pathname, O_WRONLY|O_CREAT);
+ return open(pathname, O_WRONLY|O_CREAT|O_TRUNC);
}
int open(const char* pathname, int flags)