[LTP] [PATCH] syscalls/access01: Set umask value before run case

Jan Stancek jstancek@redhat.com
Fri Sep 22 14:28:46 CEST 2017



----- Original Message -----
> The case will fail when set the umask to 0077 acquiescently in system.
> Because the value of actual mode is 'set value' & ~'default value
> for the umask' when create dir.
> So add 'umask(0022)' in setup().

We do umask(0) in ltp-pan:

# umask
0077

# /opt/ltp/runltp -p -d results -l RUNTEST.log -o RUNTEST.run.log -s access01 -f syscalls > /dev/null

# cat /opt/ltp/results/RUNTEST.log
Test Start Time: Fri Sep 22 14:24:28 2017
-----------------------------------------
Testcase                       Result     Exit Value
--------                       ------     ----------
access01                       PASS       0    

I'm aware that running tests outside of ltp-pan is sometimes useful,
so maybe we could add this to a library rather than in each test
separately? What do you think Cyril?

Regards,
Jan


More information about the ltp mailing list