Don't ignore retval of ftruncate() in log.c
This commit is contained in:
parent
fc7415a5b0
commit
616c03a9fb
@ -84,7 +84,10 @@ void close_log_file (void)
|
|||||||
void truncate_log_file (void)
|
void truncate_log_file (void)
|
||||||
{
|
{
|
||||||
lseek (log_file_fd, 0, SEEK_SET);
|
lseek (log_file_fd, 0, SEEK_SET);
|
||||||
ftruncate (log_file_fd, 0);
|
if (ftruncate (log_file_fd, 0) != 0) {
|
||||||
|
log_message (LOG_WARNING,
|
||||||
|
"Unable to truncate log file to zero length");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user