[PATCH] xlat: update ST_NOSYMFOLLOW constant

Dmitry V. Levin ldv at altlinux.org
Sun Mar 28 00:41:35 UTC 2021


On Fri, Mar 26, 2021 at 09:16:11PM -0700, deborah brouwer wrote:
[...]
> Thank you I will submit v2 of the patch to address all the issues that you mention.
> I would like to also write a test, but I am not quite sure how to approach it.
> Am I correct that the statfs tests are in tests/xstatfsx.c but that the mount flags
> are not explicitly tested?

Yes, all tests of statfs family syscalls use tests/xstatfsx.c, they do not
try to test printing of any specific ST_* flag.

> Could the flags be tested by making some additional calls
> to print_statfs with bogus filesystems mounted in different ways as in tests/mount.c?  

To test src/print_statfs.c with arbitrary statfs data, one has to tamper
with a syscall from statfs family.  We have tests that use syscall
tampering, they are usually called tests/*success.* because they use
a form of syscall tampering that's called success injection.

> Finally, would you prefer that I send the patch with the new constant separately
> from any test patch?

Since the new constant doesn't break any existing tests, it's up to you.
In this particular case I'd go for a separate patch because it's rather
simple and almost ready.


-- 
ldv


More information about the Strace-devel mailing list