Commit f0974523 authored by Tails developers's avatar Tails developers
Browse files

Use local variables in functions.

parent b7f390e3
......@@ -26,20 +26,20 @@ cleanup () {
}
error () {
CLI_TEXT="${0}: error: ${@}"
DIALOG_TEXT= "${@}
local cli_text="${0}: error: ${@}"
local dialog_text= "${@}
Unsafe Browser will exit now."
echo "${CLI_TEXT}" >&2
zenity --error --title "" --text "${DIALOG_TEXT}"
echo "${cli_text}" >&2
zenity --error --title "" --text "${dialog_text}"
cleanup
exit 1
}
warning () {
TEXT="${@}"
echo "${0}: warning: ${TEXT}" >&2
zenity --warning --title "" --text "${TEXT}"
local text="${@}"
echo "${0}: warning: ${text}" >&2
zenity --warning --title "" --text "${text}"
}
# First make sure the user really wants this
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment