Some temporary files were generated in /tmp, others in the current
directory, and none was "dpdk prefixed".
All these files have a common path prefix now: $TMPDIR/dpdk.
TMPDIR is /tmp by default.
Note: the previous use of mktemp, with a template but without -t,
was generating a file in the current directory.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
+temp=$(mktemp -t dpdk.${0##*/}.XXX.c)
-temp_cc=/tmp/${0##*/}.$$.c
+temp_cc=$(mktemp -t dpdk.${0##*/}.XXX.c)
-temp_cxx=/tmp/${0##*/}.$$.cc
+temp_cxx=$(mktemp -t dpdk.${0##*/}.XXX.cc)
trap clean_and_exit_on_sig EXIT
trap clean_and_exit_on_sig EXIT
-mapfile=`mktemp mapdb.XXXXXX`
+mapfile=`mktemp -t dpdk.mapdb.XXXXXX`
if [ -n "$1" ] ; then
tmpinput=$1
elif [ -n "$2" ] ; then
if [ -n "$1" ] ; then
tmpinput=$1
elif [ -n "$2" ] ; then
- tmpinput=$(mktemp checkpatches.XXXXXX)
+ tmpinput=$(mktemp -t dpdk.checkpatches.XXXXXX)
git format-patch --find-renames \
--no-stat --stdout -1 $commit > "$tmpinput"
else
git format-patch --find-renames \
--no-stat --stdout -1 $commit > "$tmpinput"
else
- tmpinput=$(mktemp checkpatches.XXXXXX)
+ tmpinput=$(mktemp -t dpdk.checkpatches.XXXXXX)
+tmp=$(mktemp -t dpdk.cocci.XXX)
for c in $PATCH_LIST; do
while true; do
for c in $PATCH_LIST; do
while true; do