Un fichier temporaire pouvait rester dans /tmp après l'travail

This commit is contained in:
Alan Garcia 2013-02-26 09:40:55 +00:00
parent 80c5b3fdb1
commit 1471687da2
1 changed files with 2 additions and 1 deletions

View File

@ -6,7 +6,6 @@
FLAGFILE="/var/run/alternc/refresh_slave";
TPL="/etc/alternc/templates/bind/slaveip.conf"
TARGET="/var/lib/alternc/bind/slaveip.conf"
TMP=$(mktemp /tmp/slaveip.conf.XXXX)
if [ ! -e "$FLAGFILE" ] ; then
# Nothing to do
@ -16,6 +15,8 @@ fi
# Source some functions
. /usr/lib/alternc/functions.sh
TMP=$(mktemp /tmp/slaveip.conf.XXXX)
# Get the slave IP. Remove the "newline" caracters
val=$(mysql_query "SELECT concat(ip,'::',class,'; ') FROM slaveip;"|tr '\n' ' ')