Skip to content

Commit

Permalink
systemtests: scripts/functions: use gdiff on FreeBSD
Browse files Browse the repository at this point in the history
  • Loading branch information
pstorz authored and arogge committed Nov 5, 2020
1 parent c17308e commit 22795a8
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion systemtests/scripts/functions
Original file line number Diff line number Diff line change
Expand Up @@ -630,7 +630,14 @@ check_restore_diff()
if "$rscripts/diff.pl" -s "${dest}" -d "${tmp}/bareos-restores/${dest}"; then
result=$?
fi
OUT="$(diff --no-dereference -ur --exclude="fifo*" "${dest}" "${tmp}/bareos-restores/${dest}")"

# gnu diff is required
if [ "$(uname -s)" == FreeBSD ]; then
DIFFTOOL='gdiff'
else
DIFFTOOL='diff'
fi
OUT="$($DIFFTOOL --no-dereference -ur --exclude="fifo*" "${dest}" "${tmp}/bareos-restores/${dest}")"
result=$(( result + $?))
if is_debug; then
printf "%s\n" "$OUT"
Expand Down

0 comments on commit 22795a8

Please sign in to comment.