From: Yann E. MORIN Date: Sun, 6 Apr 2014 14:59:28 +0000 (+0200) Subject: support/check-kernel-headers: use mktemp instead of hand-crafted temp file X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=78b862186555bf82e0744e2890cb3c732af59e5c;p=buildroot.git support/check-kernel-headers: use mktemp instead of hand-crafted temp file Instead of creating a temporary files with a dubious scheme, use mktemp, which purpose is exactly that: creating temporary files Reported-by: Thomas Petazzoni Signed-off-by: "Yann E. MORIN" Cc: Thomas Petazzoni Signed-off-by: Thomas Petazzoni --- diff --git a/support/scripts/check-kernel-headers.sh b/support/scripts/check-kernel-headers.sh index b511a086c1..2a0a301eda 100755 --- a/support/scripts/check-kernel-headers.sh +++ b/support/scripts/check-kernel-headers.sh @@ -8,7 +8,7 @@ HDR_M="${HDR_VER%%.*}" HDR_V="${HDR_VER#*.}" HDR_m="${HDR_V%%.*}" -EXEC="/tmp/br.check-headers.$(uuidgen)" +EXEC="$(mktemp --tmpdir check-headers.XXXXXX)" # By the time we get here, we do not always have the staging-dir # already populated (think external toolchain), so we can not use