Page MenuHomeFreeBSD

Extending the length of dirpath to fix the failure in kyua test sys/audit/inter-process:shm_unlink_success
ClosedPublic

Authored by dab on Apr 12 2022, 3:04 PM.
Tags
None
Referenced Files
Unknown Object (File)
Dec 27 2022, 5:44 PM
Unknown Object (File)
Dec 16 2022, 2:23 PM
Unknown Object (File)
Dec 14 2022, 7:04 PM
Subscribers

Details

Summary

When an overlength path is set as the temporary directory for test case sys/audit/inter-process:shm_unlink_success, the test will fail, e.g.

root@freebsd:/usr/tests/sys/audit # env TMPDIR=/var/tmp/tests/kyua kyua test inter-process:shm_unlink_success
inter-process:shm_unlink_success  ->  failed: shm_unlink.*fileforaudit.*return,success not found in auditpipe within the time limit  [10.452s]

Results file id is usr_tests_sys_audit.20220412-221852-924310
Results saved to /root/.kyua/store/results.usr_tests_sys_audit.20220412-221852-924310.db

0/1 passed (1 failed)

The root cause is that dirpath is defined too small to handle it.

Test Plan

Before code change, a truncated path was audited:

/var/tmp/tests/kyua/kyua.ymO2yO/2/work/fileforaudsubject

After code change, the full path was audited:

/var/tmp/tests/kyua/kyua.372NJL/2/work/fileforauditsubject

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable