mbox series

[0/4] Remove double or trailing slashes in TMPDIR in C API

Message ID 20240207160628.125908-1-pvorel@suse.cz
Headers show
Series Remove double or trailing slashes in TMPDIR in C API | expand

Message

Petr Vorel Feb. 7, 2024, 4:06 p.m. UTC
Hi,

the initial motivation to avoid problems when people set
TMPDIR=/var/tmp/ instead of TMPDIR=/var/tmp (which is needed for
runtest/fs or runtest/syscalls since [1]).

Kind regards,
Petr

[1] https://lore.kernel.org/ltp/20240201101603.GA78772@pevik/

Petr Vorel (4):
  lib/tst_tmpdir: Normalize user defined TMPDIR
  lib: Add test for tst_tmpdir
  tst_test.sh: Print warning if slashes in $TMPDIR
  lib: Improve doc related to $TMPDIR default value

 include/tst_defaults.h        |  5 ++--
 lib/newlib_tests/runtest.sh   |  2 +-
 lib/newlib_tests/tst_tmpdir.c | 48 +++++++++++++++++++++++++++++++++++
 lib/tst_tmpdir.c              | 20 ++++++++++++++-
 testcases/lib/tst_test.sh     | 17 ++++++++++---
 5 files changed, 84 insertions(+), 8 deletions(-)
 create mode 100644 lib/newlib_tests/tst_tmpdir.c