Append to log file, not overwrite

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui 2018-12-21 23:02:19 +00:00
parent 8bb7027393
commit e211c395fa
No known key found for this signature in database
GPG Key ID: 37C999F617EA1A47
1 changed files with 1 additions and 1 deletions

View File

@ -264,7 +264,7 @@ static const struct log_ops file_logger_ops = {
}; };
struct log_target *file_logger_new(const char *filename) { struct log_target *file_logger_new(const char *filename) {
FILE *f = fopen(filename, "w+"); FILE *f = fopen(filename, "a");
if (!f) { if (!f) {
return NULL; return NULL;
} }