This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 4/5] io: Add io/tst-lchmod covering lchmod and fchmodat
- From: Florian Weimer <fw at deneb dot enyo dot de>
- To: Adhemerval Zanella <adhemerval dot zanella at linaro dot org>
- Cc: libc-alpha at sourceware dot org
- Date: Wed, 12 Feb 2020 19:53:48 +0100
- Subject: Re: [PATCH 4/5] io: Add io/tst-lchmod covering lchmod and fchmodat
- References: <cover.1579723048.git.fweimer@redhat.com> <e2d83306b7898deac80e42279d4e175553241320.1579723048.git.fweimer@redhat.com> <87a75pjga5.fsf@oldenburg2.str.redhat.com> <c50134ec-3df6-2d83-8ff0-377a91d5efc2@linaro.org>
* Adhemerval Zanella:
> On 11/02/2020 12:27, Florian Weimer wrote:
>> * Florian Weimer:
>>
>>> + /* Without AT_SYMLINK_NOFOLLOW, changing the permissions should
>>> + work as before. */
>>> + arg = select_path (do_relative_path, path_file, "file");
>>> + TEST_COMPARE (chmod_func (fd, arg, 3, 0), 0);
>>> + xstat (path_file, &st);
>>> + TEST_COMPARE (st.st_mode & 0777, 3);
>>> + /* But with AT_SYMLINK_NOFOLLOW, even if we originally had
>>> + support, we may have lost it. */
>>> + ret = chmod_func (fd, arg, 2, 0);
>>
>> The last line misses AT_SYMLINK_NOFOLLOW. The version below (which I'm
>> going to commit) fixes this and adds another check.
>
> I am seeing the following failures on ext2/ext3 on both powerpc64le
> (4.18.0-80.7.2.el7.ppc64le) and aarch64 (4.12.13).
Yeah, please see this thread:
<https://sourceware.org/ml/libc-alpha/2020-02/msg00467.html>
It affects more than XFS, but apparently not tmpfs (which is what I
happened to use during development of the emulation).
I'll patch this up tomorrow. It'll considerably simplify the test
case, too.