tests: Avoid using mktemp - scc - simple c99 compiler
HTML git clone git://git.simple-cc.org/scc
DIR Log
DIR Files
DIR Refs
DIR Submodules
DIR README
DIR LICENSE
---
DIR commit dc99102efafb82f90ae3f39ce98f30e06f94335b
DIR parent 68568d529414af1522832b6fe63bf163306e0c8f
HTML Author: Roberto E. Vargas Caballero <k0ga@shike2.net>
Date: Sat, 24 Jan 2026 11:50:19 +0100
tests: Avoid using mktemp
Mktemp is not posix and it is usually not needed for our use case.
Diffstat:
M tests/ar/execute/0019-list.sh | 2 +-
M tests/ar/execute/0038-update.sh | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
---
DIR diff --git a/tests/ar/execute/0019-list.sh b/tests/ar/execute/0019-list.sh
@@ -5,7 +5,7 @@ set -e
trap 'rm -f file.a $tmp1' EXIT
trap 'exit $?' HUP INT TERM
-tmp1=`mktemp`
+tmp1=tmp1.$$
############################################################################
#print 3rd member
DIR diff --git a/tests/ar/execute/0038-update.sh b/tests/ar/execute/0038-update.sh
@@ -5,8 +5,8 @@ set -e
trap 'rm -f file* $tmp1' EXIT
trap 'exit $?' HUP INT TERM
-tmp1=`mktemp`
-tmp2=`mktemp`
+tmp1=tmp1.$$
+tmp2=tmp2.$$
############################################################################
#Update without parameters