summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2013-10-12 15:52:55 (EDT)
committer P. J. McDermott <pjm@nac.net>2013-10-12 15:52:55 (EDT)
commitf776f91033ff7bb4ecea0d10db5c920467d53458 (patch)
tree4c9cb587ed0b8beb84d385809a77348c2895c038 /src
parenta46f6d8e5d1c15cc463887030ce88d7af71971ad (diff)
pro-archman: Use error() for "lock_fail" message.
Diffstat (limited to 'src')
-rw-r--r--src/pro-archman.sh4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/pro-archman.sh b/src/pro-archman.sh
index dd8fe2e..732db76 100644
--- a/src/pro-archman.sh
+++ b/src/pro-archman.sh
@@ -107,9 +107,7 @@ main()
mkdir -p "${opt_base_dir}/.db"
lock="${opt_base_dir}/.db/lock"
if ! (set -C; printf '%d\n' "${$}" >"${lock}") 2>/dev/null; then
- printf '%s: Error: ' "${0##*/}" >&2
- printf "$(get_msg 'lock_fail')\n" >&2
- exit 2
+ error 2 "$(get_msg 'lock_fail')"
fi
get_conf
run_cmd "${@}"