]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
fs-posix: Support FS_METADATA_WRITE_FNAME for fs_copy()
authorTimo Sirainen <timo.sirainen@dovecot.fi>
Tue, 22 May 2018 13:06:15 +0000 (16:06 +0300)
committerTimo Sirainen <timo.sirainen@dovecot.fi>
Fri, 25 May 2018 07:35:05 +0000 (10:35 +0300)
src/lib-fs/fs-posix.c

index 1a257fbeefff9ce183b8bd1862824c12182c33b3..82bf5306a9c0747b9296f12294f764ec80507f04 100644 (file)
@@ -764,6 +764,7 @@ static int fs_posix_copy(struct fs_file *_src, struct fs_file *_dest)
        unsigned int try_count = 0;
        int ret;
 
+       fs_posix_write_rename_if_needed(dest);
        ret = link(src->full_path, dest->full_path);
        if (errno == EEXIST && dest->open_mode == FS_OPEN_MODE_REPLACE) {
                /* destination file already exists - replace it */