From 74402bf01a561c1e050589941ac91df44577d118 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 13 Jun 2023 09:49:35 +0200 Subject: [PATCH] coredump: port over code to new LINK_TMPFILE_SYNC flag --- src/coredump/coredump.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/coredump/coredump.c b/src/coredump/coredump.c index ac1c26e828..0fe19894e5 100644 --- a/src/coredump/coredump.c +++ b/src/coredump/coredump.c @@ -269,11 +269,7 @@ static int fix_permissions( (void) fix_acl(fd, uid, allow_user); (void) fix_xattr(fd, context); - r = fsync_full(fd); - if (r < 0) - return log_error_errno(r, "Failed to sync coredump %s: %m", coredump_tmpfile_name(filename)); - - r = link_tmpfile(fd, filename, target, /* flags= */ 0); + r = link_tmpfile(fd, filename, target, LINK_TMPFILE_SYNC); if (r < 0) return log_error_errno(r, "Failed to move coredump %s into place: %m", target);