forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
torture: Use mktemp instead of guessing at unique names
This commit drags the rcutorture scripting kicking and screaming into the twenty-first century by making use of the BSD-derived mktemp command to create temporary files and directories. In happy contrast to many of its ill-behaved predecessors, mktemp seems to actually work reasonably reliably! Signed-off-by: Paul E. McKenney <[email protected]>
- Loading branch information
1 parent
50527f7
commit c211ae9
Showing
15 changed files
with
20 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,9 +7,8 @@ | |
# | ||
# Authors: Paul E. McKenney <[email protected]> | ||
|
||
T=${TMPDIR-/tmp}/abat-chk-config.sh.$$ | ||
T="`mktemp -d ${TMPDIR-/tmp}/configcheck.sh.XXXXXX`" | ||
trap 'rm -rf $T' 0 | ||
mkdir $T | ||
|
||
cat $1 > $T/.config | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,9 +15,8 @@ | |
# | ||
# Authors: Paul E. McKenney <[email protected]> | ||
|
||
T=${TMPDIR-/tmp}/configinit.sh.$$ | ||
T="`mktemp -d ${TMPDIR-/tmp}/configinit.sh.XXXXXX`" | ||
trap 'rm -rf $T' 0 | ||
mkdir $T | ||
|
||
# Capture config spec file. | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,9 +13,8 @@ | |
# | ||
# Authors: Paul E. McKenney <[email protected]> | ||
|
||
T=${TMPDIR-/tmp}/kvm-test-1-run-batch.sh.$$ | ||
T="`mktemp -d ${TMPDIR-/tmp}/kvm-test-1-run-batch.sh.XXXXXX`" | ||
trap 'rm -rf $T' 0 | ||
mkdir $T | ||
|
||
echo ---- Running batch $* | ||
# Check arguments | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,9 +17,8 @@ | |
# | ||
# Authors: Paul E. McKenney <[email protected]> | ||
|
||
T=${TMPDIR-/tmp}/kvm-test-1-run-qemu.sh.$$ | ||
T="`mktemp -d ${TMPDIR-/tmp}/kvm-test-1-run-qemu.sh.XXXXXX`" | ||
trap 'rm -rf $T' 0 | ||
mkdir $T | ||
|
||
resdir="$1" | ||
if ! test -d "$resdir" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,9 +25,8 @@ | |
# | ||
# Authors: Paul E. McKenney <[email protected]> | ||
|
||
T=${TMPDIR-/tmp}/kvm-test-1-run.sh.$$ | ||
T="`mktemp -d ${TMPDIR-/tmp}/kvm-test-1-run.sh.XXXXXX`" | ||
trap 'rm -rf $T' 0 | ||
mkdir $T | ||
|
||
. functions.sh | ||
. $CONFIGFRAG/ver_functions.sh | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters