mirror of
https://github.com/acmesh-official/acme.sh.git
synced 2025-05-05 23:17:41 +00:00
Remove bash unique string manipulation, replace with cut function.
This commit is contained in:
parent
d059831da1
commit
2d4804274d
@ -375,8 +375,8 @@ _freedns_urlencode() {
|
|||||||
length="${#1}"
|
length="${#1}"
|
||||||
i=0
|
i=0
|
||||||
while [ "$i" -lt "$length" ]; do
|
while [ "$i" -lt "$length" ]; do
|
||||||
c="${1:i:1}"
|
|
||||||
i="$(_math "$i" + 1)"
|
i="$(_math "$i" + 1)"
|
||||||
|
c="$(echo "$1" | cut -c "$i")"
|
||||||
case $c in
|
case $c in
|
||||||
[a-zA-Z0-9.~_-]) printf '%s' "$c" ;;
|
[a-zA-Z0-9.~_-]) printf '%s' "$c" ;;
|
||||||
*) printf '%%%02X' "'$c" ;;
|
*) printf '%%%02X' "'$c" ;;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user