deploy: Ensure that any modified config files are fsync()d

It really wouldn't do for one to be missing one's ssh keys for
example...
This commit is contained in:
Colin Walters 2014-04-08 17:37:35 -04:00
parent 1b16553600
commit 38feca0e4d
1 changed files with 5 additions and 0 deletions

View File

@ -86,6 +86,11 @@ copy_modified_config_file (GFile *orig_etc,
if (!g_file_copy (src, dest, G_FILE_COPY_OVERWRITE | G_FILE_COPY_NOFOLLOW_SYMLINKS | G_FILE_COPY_ALL_METADATA,
cancellable, NULL, NULL, error))
goto out;
if (g_file_info_get_file_type (src_info) == G_FILE_TYPE_REGULAR)
{
if (!gs_file_sync_data (dest, cancellable, error))
goto out;
}
}
ret = TRUE;