changeset 22268:382ee00c9669

lib: file_create_locked() - update lock path after link()
author Timo Sirainen <timo.sirainen@dovecot.fi>
date Thu, 22 Jun 2017 10:35:16 +0300
parents ce98be82d4d6
children b553f6960cb9
files src/lib/file-create-locked.c
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib/file-create-locked.c	Thu Jun 22 09:05:06 2017 +0300
+++ b/src/lib/file-create-locked.c	Thu Jun 22 10:35:16 2017 +0300
@@ -80,6 +80,7 @@
 		}
 		file_lock_free(lock_r);
 	} else {
+		file_lock_set_path(*lock_r, path);
 		i_unlink_if_exists(str_c(temp_path));
 		*fd_r = fd;
 		return 1;