Fix puny-encoding all-non-ASCII domains
* puny.el (puny-encode-string): Fix the all-non-ASCII encoding case.
This commit is contained in:
parent
1efc5f8b09
commit
341feb3a26
1 changed files with 5 additions and 1 deletions
|
@ -47,7 +47,11 @@ For instance, \"bücher\" => \"xn--bcher-kva\"."
|
|||
string)))
|
||||
(if (= (length ascii) (length string))
|
||||
string
|
||||
(concat "xn--" ascii "-" (puny-encode-complex (length ascii) string)))))
|
||||
(concat "xn--"
|
||||
(if (null ascii)
|
||||
""
|
||||
(concat ascii "-"))
|
||||
(puny-encode-complex (length ascii) string)))))
|
||||
|
||||
(defun puny-decode-domain (domain)
|
||||
"Decode DOMAIN according to the IDNA/punycode algorith.
|
||||
|
|
Loading…
Add table
Reference in a new issue