diff options
author | mboelen <michael@cisofy.com> | 2016-01-11 03:04:38 +0300 |
---|---|---|
committer | mboelen <michael@cisofy.com> | 2016-01-11 03:04:38 +0300 |
commit | e0e56f2cdcfc94b847142bf8d3b68f39ef6d9b50 (patch) | |
tree | 0fbbdb3c69f8be52cff0cea37c5118941c11bbec /include/helper_update | |
parent | 1cb90916eea687a4f28ec5ccc4f08e0217d7c499 (diff) |
Use CreateTempFile for creation of temporary files
Diffstat (limited to 'include/helper_update')
-rw-r--r-- | include/helper_update | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/include/helper_update b/include/helper_update index 60529c4b..5bee2b07 100644 --- a/include/helper_update +++ b/include/helper_update @@ -84,11 +84,12 @@ if [ "$1" = "release" ]; then # Normal update FULLPATH="${UPDATE_SERVER_PROTOCOL}://${UPDATE_SERVER_ADDRESS}${UPDATE_LATEST_VERSION_INFO}" - TMP_FILE=`mktemp /tmp/audit.XXXXXXXXXX` - if [ "${TMP_FILE}" = "" ]; then - Display --indent 2 --text "Could not create a temporary file in /tmp with mktemp. Aborting.." - ExitFatal - fi + + # Create temporary file + CreateTempFile + TMP_FILE="${TEMP_FILE}" + if [ "${TMP_FILE}" = "" ]; then Display --indent 2 --text "Could not create a temporary file. Exiting..."; ExitFatal; fi + Display --indent 2 --text "${CYAN}[Phase 1] Downloading details${NORMAL}" if [ ! "${WGET_EXISTS}" = "" ]; then logtext "Using wget to download release information" |