Fix regression in #198

For enddate conversion there's no need to tell ``date``
to convert the time including the TZ. MacOS X' date hiccups
when this will be done (strangely, FreeBSDs are fine).
This commit is contained in:
Dirk 2018-04-09 09:07:51 +02:00
parent 7d4f36493c
commit c96d01d376

View File

@ -6232,7 +6232,7 @@ certificate_info() {
# best we are able to do under OpenBSD
days2expire=""
else
days2expire=$(( $(parse_date "$enddate" "+%s" "%F %H:%M %z") - $(LC_ALL=C date "+%s") )) # in seconds
days2expire=$(( $(parse_date "$enddate" "+%s" "%F %H:%M") - $(LC_ALL=C date "+%s") )) # in seconds
days2expire=$((days2expire / 3600 / 24 ))
if grep -q "^Let's Encrypt Authority" <<< "$issuer_CN"; then # we take the half of the thresholds for LE certificates