1
0
mirror of https://github.com/deajan/obackup.git synced 2024-11-15 04:03:41 +01:00

Moved TrapQuit to script entry point

This commit is contained in:
deajan 2018-10-10 00:08:49 +02:00
parent c33e6b69c1
commit 5a51855691

View File

@ -7,7 +7,7 @@ PROGRAM="obackup"
AUTHOR="(C) 2013-2018 by Orsiris de Jong" AUTHOR="(C) 2013-2018 by Orsiris de Jong"
CONTACT="http://www.netpower.fr/obackup - ozy@netpower.fr" CONTACT="http://www.netpower.fr/obackup - ozy@netpower.fr"
PROGRAM_VERSION=2.1-RC1 PROGRAM_VERSION=2.1-RC1
PROGRAM_BUILD=2018093008 PROGRAM_BUILD=2018101001
IS_STABLE=no IS_STABLE=no
#### Execution order #__WITH_PARANOIA_DEBUG #### Execution order #__WITH_PARANOIA_DEBUG
@ -1776,9 +1776,6 @@ function Init {
local hosturiandpath local hosturiandpath
local hosturi local hosturi
trap TrapStop INT QUIT TERM HUP
trap TrapQuit EXIT
## Test if target dir is a ssh uri, and if yes, break it down it its values ## Test if target dir is a ssh uri, and if yes, break it down it its values
if [ "${REMOTE_SYSTEM_URI:0:6}" == "ssh://" ] && [ "$BACKUP_TYPE" != "local" ]; then if [ "${REMOTE_SYSTEM_URI:0:6}" == "ssh://" ] && [ "$BACKUP_TYPE" != "local" ]; then
REMOTE_OPERATION="yes" REMOTE_OPERATION="yes"
@ -1912,6 +1909,9 @@ function Usage {
exit 128 exit 128
} }
#### SCRIPT ENTRY POINT ####
trap TrapQuit EXIT
# Command line argument flags # Command line argument flags
_DRYRUN=false _DRYRUN=false
no_maxtime=false no_maxtime=false