hostname-util: explain what 'LDH' is

This commit is contained in:
Lennart Poettering 2020-12-11 16:26:04 +01:00
parent 1feb8eee2d
commit 9e815cf2c2
1 changed files with 2 additions and 0 deletions

View File

@ -89,6 +89,8 @@ int gethostname_strict(char **ret) {
}
bool valid_ldh_char(char c) {
/* "LDH" → "Letters, digits, hyphens", as per RFC 5890, Section 2.3.1 */
return
(c >= 'a' && c <= 'z') ||
(c >= 'A' && c <= 'Z') ||