Hi!
> +/*
> + * EROFS need superuser privilege (mount and umount a readonly file system),
> + * but the other error values tests need a normal user.
> + * So we first call setup1() with superuser privilege to test EROFS, and then
> + * use setup() to call setuid()to change the real user id to perform
> + * other tests.
> + */

Ah, this adds unexpected complexity and does not work test looping :(.

I've looked closely on the test code and the problem is that acces uses
real user id so we have to drop the rights to check the access call but
we need to be able to unmount the fs at the end of the test, which is
privileged operation.

Only solution that I have currenlty in mind is to run the test from
within the child process that drops the rights so that the parent
can perform the cleanup at the end, but again this adds unnecessary
complexity.

Was this problem the original reason why you added the new testcase for
the EROFS part? If so, you should have spoken as I did not foresee that
we will hit this problem.

So we should either proceed with the previous version (EROFS in separate
test) or move the code to child processes. The first solution seems
better to me, what do you think?

-- 
Cyril Hrubis
[email protected]

------------------------------------------------------------------------------
Android is increasing in popularity, but the open development platform that
developers love is also attractive to malware creators. Download this white
paper to learn more about secure code signing practices that can help keep
Android apps secure.
http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to