Fixed some low severity bugs
This commit is contained in:
parent
46cf6a8b36
commit
a1c29f62d5
|
@ -28,6 +28,8 @@ UNDER WORK
|
||||||
RECENT CHANGES
|
RECENT CHANGES
|
||||||
--------------
|
--------------
|
||||||
|
|
||||||
|
- Fixed an issue with empty RSYNC_EXCLUDE_FILES
|
||||||
|
- Lowered default compression level for email alerts (for low end systems
|
||||||
- Prevent exclude pattern globbing before the pattern reaches the rsync cmd
|
- Prevent exclude pattern globbing before the pattern reaches the rsync cmd
|
||||||
- Fixed some missing child pids for time control to work
|
- Fixed some missing child pids for time control to work
|
||||||
- Prevent creation of a sync-id less log file when DEBUG is set
|
- Prevent creation of a sync-id less log file when DEBUG is set
|
||||||
|
|
11
osync.sh
11
osync.sh
|
@ -4,7 +4,7 @@ PROGRAM="Osync" # Rsync based two way sync engine with fault tolerance
|
||||||
AUTHOR="(L) 2013-2015 by Orsiris \"Ozy\" de Jong"
|
AUTHOR="(L) 2013-2015 by Orsiris \"Ozy\" de Jong"
|
||||||
CONTACT="http://www.netpower.fr/osync - ozy@netpower.fr"
|
CONTACT="http://www.netpower.fr/osync - ozy@netpower.fr"
|
||||||
PROGRAM_VERSION=0.99RC4
|
PROGRAM_VERSION=0.99RC4
|
||||||
PROGRAM_BUILD=1202201501
|
PROGRAM_BUILD=1802201501
|
||||||
|
|
||||||
## type doesn't work on platforms other than linux (bash). If if doesn't work, always assume output is not a zero exitcode
|
## type doesn't work on platforms other than linux (bash). If if doesn't work, always assume output is not a zero exitcode
|
||||||
if ! type -p "$BASH" > /dev/null
|
if ! type -p "$BASH" > /dev/null
|
||||||
|
@ -722,10 +722,11 @@ function CheckMinimumSpace
|
||||||
|
|
||||||
function RsyncExcludePattern
|
function RsyncExcludePattern
|
||||||
{
|
{
|
||||||
|
# Disable globbing so wildcards from exclusions don't get expanded
|
||||||
set -f
|
set -f
|
||||||
OLD_IFS=$IFS
|
OLD_IFS=$IFS
|
||||||
IFS=$PATH_SEPARATOR_CHAR
|
IFS=$PATH_SEPARATOR_CHAR
|
||||||
for excludedir in $RSYNC_EXCLUDE_PATTERN
|
for excludedir in "$RSYNC_EXCLUDE_PATTERN"
|
||||||
do
|
do
|
||||||
if [ "$RSYNC_EXCLUDE" == "" ]
|
if [ "$RSYNC_EXCLUDE" == "" ]
|
||||||
then
|
then
|
||||||
|
@ -740,7 +741,7 @@ function RsyncExcludePattern
|
||||||
|
|
||||||
function RsyncExcludeFrom
|
function RsyncExcludeFrom
|
||||||
{
|
{
|
||||||
if [ ! $RSYNC_EXCLUDE_FROM == "" ]
|
if [ ! "$RSYNC_EXCLUDE_FROM" == "" ]
|
||||||
then
|
then
|
||||||
## Check if the exclude list has a full path, and if not, add the config file path if there is one
|
## Check if the exclude list has a full path, and if not, add the config file path if there is one
|
||||||
if [ "$(basename $RSYNC_EXCLUDE_FROM)" == "$RSYNC_EXCLUDE_FROM" ]
|
if [ "$(basename $RSYNC_EXCLUDE_FROM)" == "$RSYNC_EXCLUDE_FROM" ]
|
||||||
|
@ -748,7 +749,7 @@ function RsyncExcludeFrom
|
||||||
RSYNC_EXCLUDE_FROM=$(dirname $ConfigFile)/$RSYNC_EXCLUDE_FROM
|
RSYNC_EXCLUDE_FROM=$(dirname $ConfigFile)/$RSYNC_EXCLUDE_FROM
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -e $RSYNC_EXCLUDE_FROM ]
|
if [ -e "$RSYNC_EXCLUDE_FROM" ]
|
||||||
then
|
then
|
||||||
RSYNC_EXCLUDE="$RSYNC_EXCLUDE --exclude-from=\"$RSYNC_EXCLUDE_FROM\""
|
RSYNC_EXCLUDE="$RSYNC_EXCLUDE --exclude-from=\"$RSYNC_EXCLUDE_FROM\""
|
||||||
fi
|
fi
|
||||||
|
@ -1846,7 +1847,7 @@ function Init
|
||||||
)
|
)
|
||||||
|
|
||||||
## Set compression executable and extension
|
## Set compression executable and extension
|
||||||
COMPRESSION_LEVEL=9
|
COMPRESSION_LEVEL=3
|
||||||
if type -p xz > /dev/null 2>&1
|
if type -p xz > /dev/null 2>&1
|
||||||
then
|
then
|
||||||
COMPRESSION_PROGRAM="| xz -$COMPRESSION_LEVEL"
|
COMPRESSION_PROGRAM="| xz -$COMPRESSION_LEVEL"
|
||||||
|
|
Loading…
Reference in New Issue