diff --git a/client/CHANGELOG.md b/client/CHANGELOG.md index 8dc9a9a..1221d36 100644 --- a/client/CHANGELOG.md +++ b/client/CHANGELOG.md @@ -16,8 +16,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed +* Make start_time and stop_time compatible with OpenBSD + ### Security ## [22.03] -Split client and server parts of the project \ No newline at end of file +Split client and server parts of the project diff --git a/client/zzz_evobackup b/client/zzz_evobackup index 20b619c..09234d2 100755 --- a/client/zzz_evobackup +++ b/client/zzz_evobackup @@ -505,8 +505,13 @@ fi STOP_EPOCH=$(/bin/date +%s) -start_time=$(/bin/date --date="@${START_EPOCH}" +"${DATE_FORMAT}") -stop_time=$(/bin/date --date="@${STOP_EPOCH}" +"${DATE_FORMAT}") +if [ "${SYSTEM}" = "openbsd" ]; then + start_time=$(/bin/date -f "%s" -j "${START_EPOCH}" +"${DATE_FORMAT}") + stop_time=$(/bin/date -f "%s" -j "${STOP_EPOCH}" +"${DATE_FORMAT}") +else + start_time=$(/bin/date --date="@${START_EPOCH}" +"${DATE_FORMAT}") + stop_time=$(/bin/date --date="@${STOP_EPOCH}" +"${DATE_FORMAT}") +fi duration=$(( STOP_EPOCH - START_EPOCH )) log "STOP GLOBAL - start='${start_time}' stop='${stop_time}' duration=${duration}s"