You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tar/SOURCES/tar-1.28-atime-rofs.patch

35 lines
962 B

From 71769b9ea3c12b7fbb39fee2e9f4a4c1c36c0d0b Mon Sep 17 00:00:00 2001
From: rpm-build <rpm-build>
Date: Mon, 28 Jul 2014 08:13:31 +0200
Subject: [PATCH 4/9] utime & read-only FS
Ignore errors from setting utime() for source file on read-only
file-system.
Resolves: #500742
Upstream bugreport (still downstream):
http://lists.gnu.org/archive/html/bug-tar/2009-06/msg00016.html
---
src/create.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/create.c b/src/create.c
index e2f4ede..f644f23 100644
--- a/src/create.c
+++ b/src/create.c
@@ -1824,7 +1824,8 @@ dump_file0 (struct tar_stat_info *st, char const *name, char const *p)
}
else if (atime_preserve_option == replace_atime_preserve
&& fd && (is_dir || original_size != 0)
- && set_file_atime (fd, parentfd, name, st->atime) != 0)
+ && set_file_atime (fd, parentfd, name, st->atime) != 0
+ && errno != EROFS )
utime_error (p);
}
--
1.9.3