Check existing flags with an lstat(), not a stat().
Otherwise, restoring symlinks with flags consistently fails (unionfs likes to set 'opaque' flags).
This commit is contained in:
parent
eafe3176c4
commit
4061e9fa91
@ -1243,7 +1243,7 @@ set_fflags(struct archive *a, int fd, const char *name, mode_t mode,
|
||||
/* Already have stat() data available. */
|
||||
} else if (fd >= 0 && fstat(fd, &extract->st) == 0)
|
||||
extract->pst = &extract->st;
|
||||
else if (stat(name, &extract->st) == 0)
|
||||
else if (lstat(name, &extract->st) == 0)
|
||||
extract->pst = &extract->st;
|
||||
else {
|
||||
archive_set_error(a, errno,
|
||||
|
Loading…
x
Reference in New Issue
Block a user