]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Start to address the race issue between restoring a file's contents
authorTim Kientzle <kientzle@FreeBSD.org>
Sat, 21 May 2005 19:45:56 +0000 (19:45 +0000)
committerTim Kientzle <kientzle@FreeBSD.org>
Sat, 21 May 2005 19:45:56 +0000 (19:45 +0000)
commitb33c1067f883feaa980adfa44ae0d2ea06e435ae
tree204b4462e048dc1ac7dd860da0d069286d7ae4c6
parent21805f33bfc10c11a5f7f7ef29c0c5641e548019
Start to address the race issue between restoring a file's contents
and restoring the metadata.  In particular, the metadata-restore
functions now all accept a file descriptor and a pathname.  If the
file descriptor is set and the platform supports the appropriate
syscall, restore the metadata through the file descriptor.  Otherwise,
restore it through the pathname.  This is complicated by varying
syscall support (FreeBSD has an fchmod(2) but no fchflags(2), for
example) and because non-file entries don't have an fd to use in
restoring attributes (for example, mknod(2) doesn't return a file
handle).

MFC after: 14 days
lib/libarchive/Makefile
lib/libarchive/archive_platform.h
lib/libarchive/archive_read_extract.c
lib/libarchive/configure.ac.in