diff options
author | 2014-05-15 18:49:12 -0500 | |
---|---|---|
committer | 2014-05-15 18:49:12 -0500 | |
commit | 87c53ea58befef48677846693aab445df1850e16 (patch) | |
tree | 3fc27a7b40862208daf522b333bdfe46a7c79b0c | |
parent | 36689a76e79bf6e6231f6f03cbfad297d4411588 (diff) | |
download | pseudo-87c53ea58befef48677846693aab445df1850e16.tar.gz pseudo-87c53ea58befef48677846693aab445df1850e16.tar.bz2 pseudo-87c53ea58befef48677846693aab445df1850e16.zip |
fchmodat: don't pass AT_SYMLINK_NOFOLLOWseebs/xattr
underlying fchmodat() will just fail, but GNU tar calls it that way
anyway, figuring it'll just retry on failure, but we don't report
the failure. Nor do we want to, because that's expensive and slow
and will result in additional database round trips. But I don't want
to fail out right away, so for now, just strip the flag.
-rw-r--r-- | ChangeLog.txt | 6 | ||||
-rw-r--r-- | ports/unix/guts/fchmodat.c | 7 |
2 files changed, 12 insertions, 1 deletions
diff --git a/ChangeLog.txt b/ChangeLog.txt index d4fdeec..27a6fcf 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -1,3 +1,9 @@ +2014-05-15: + * (seebs) drop flags when calling fchmodat() to appease GNU tar. + +2014-04-24: + * (seebs) extended attribute support + 2014-01-23: * (seebs) mknod wasn't calling mknodat. * (seebs) mkdirat wasn't recording the logical DB mode for directories diff --git a/ports/unix/guts/fchmodat.c b/ports/unix/guts/fchmodat.c index 36a8490..c18fd4c 100644 --- a/ports/unix/guts/fchmodat.c +++ b/ports/unix/guts/fchmodat.c @@ -54,7 +54,12 @@ * specified, we already bailed previously. */ real_chmod(path, PSEUDO_FS_MODE(mode, S_ISDIR(buf.st_mode))); #else - real_fchmodat(dirfd, path, PSEUDO_FS_MODE(mode, S_ISDIR(buf.st_mode)), flags); + /* AT_SYMLINK_NOFOLLOW isn't supported by fchmodat. GNU tar + * tries to use it anyway, figuring it can just retry if that + * fails. But we never fail, so they don't retry. So we drop + * the flag here. + */ + real_fchmodat(dirfd, path, PSEUDO_FS_MODE(mode, S_ISDIR(buf.st_mode)), 0); #endif /* we ignore a failure from underlying fchmod, because pseudo * may believe you are permitted to change modes that the filesystem |