Browse Source
Merge pull request #1746 from j-c-m/time2str-dev
BSD fix _time2str()
pull/1749/head
neil
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
5 additions and
5 deletions
-
acme.sh
|
@ -1374,17 +1374,17 @@ _url_replace() { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
_time2str() { |
|
|
_time2str() { |
|
|
#Linux |
|
|
|
|
|
if date -u -d@"$1" 2>/dev/null; then |
|
|
|
|
|
|
|
|
#BSD |
|
|
|
|
|
if date -u -r "$1" 2>/dev/null; then |
|
|
return |
|
|
return |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
#BSD |
|
|
|
|
|
if date -u -r "$1" 2>/dev/null; then |
|
|
|
|
|
|
|
|
#Linux |
|
|
|
|
|
if date -u -d@"$1" 2>/dev/null; then |
|
|
return |
|
|
return |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
#Soaris |
|
|
|
|
|
|
|
|
#Solaris |
|
|
if _exists adb; then |
|
|
if _exists adb; then |
|
|
_t_s_a=$(echo "0t${1}=Y" | adb) |
|
|
_t_s_a=$(echo "0t${1}=Y" | adb) |
|
|
echo "$_t_s_a" |
|
|
echo "$_t_s_a" |
|
|