summaryrefslogtreecommitdiffstats
path: root/src/wireless
diff options
context:
space:
mode:
authorJim Pryor <profjim@jimpryor.net>2009-08-11 18:49:05 +0200
committerJames Rayner <james@archlinux.org>2009-09-07 11:50:23 +0200
commit3ae7e093c27350ced6ffaf99a3bca6bc56c559b8 (patch)
tree33739118bd44316ad4b44506bc231835329ad1f5 /src/wireless
parentc2b6decd51289abe3d969f305f709fb4243fe6f1 (diff)
downloadnetctl-3ae7e093c27350ced6ffaf99a3bca6bc56c559b8.tar.gz
netctl-3ae7e093c27350ced6ffaf99a3bca6bc56c559b8.tar.xz
respect TMPDIR
Signed-off-by: Jim Pryor <profjim@jimpryor.net>
Diffstat (limited to 'src/wireless')
-rw-r--r--src/wireless6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/wireless b/src/wireless
index 81a8408..e778627 100644
--- a/src/wireless
+++ b/src/wireless
@@ -91,7 +91,7 @@ list_networks()
# is hard, obscure and kinda nasty. This is simpler and clearer.
[[ -z "$INTERFACE" ]] && return 1
- essids=$(mktemp /tmp/essid.XXXXXXXX)
+ essids=$(mktemp --tmpdir essid.XXXXXXXX)
wpa_supplicant -B -i$INTERFACE -Dwext -C/var/run/wpa_supplicant -P/var/run/wpa_supplicant.pid
@@ -115,8 +115,8 @@ list_networks()
kill $(cat /var/run/wpa_supplicant.pid)
# File of 0 length, ie. no ssid's.
- if [[ ! -s $essids ]]; then
- rm -f $essids
+ if [[ ! -s "$essids" ]]; then
+ rm -f "$essids"
return 1
fi