Mercurial > dovecot > core-2.2
changeset 21525:cea8065bd571
lib-index: clear file->mmap_size only after logging it
Logging the error with size=0 loses information.
author | Martti Rannanjärvi <martti.rannanjarvi@dovecot.fi> |
---|---|
date | Mon, 13 Feb 2017 09:09:28 +0200 |
parents | c14dda2ca252 |
children | 6109df9e091b |
files | src/lib-index/mail-transaction-log-file.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-index/mail-transaction-log-file.c Mon Feb 13 09:08:25 2017 +0200 +++ b/src/lib-index/mail-transaction-log-file.c Mon Feb 13 09:09:28 2017 +0200 @@ -1635,12 +1635,12 @@ file->fd, 0); if (file->mmap_base == MAP_FAILED) { file->mmap_base = NULL; - file->mmap_size = 0; if (ioloop_time != file->last_mmap_error_time) { file->last_mmap_error_time = ioloop_time; log_file_set_syscall_error(file, t_strdup_printf( "mmap(size=%"PRIuSIZE_T")", file->mmap_size)); } + file->mmap_size = 0; return -1; }