Software / code / prosody
Annotate
teal-src/util/format.d.tl @ 13121:332e95f75dbb 0.12
util.prosodyctl.check: Fix error where hostname can't be turned into A label
Where gethostname or tohostname returns an invalid name, e.g. containing
underscores or something, to_ascii would reject this and return nil,
which triggers an error in the dns lookup.
Reported by prova2 in the chat, for whom tohostname returned a long name
containing underscores.
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Wed, 31 May 2023 14:08:19 +0200 |
| parent | 11432:113f3912c7cb |
| rev | line source |
|---|---|
|
11432
113f3912c7cb
util: Add Teal interface definition files
Kim Alvefur <zash@zash.se>
parents:
diff
changeset
|
1 local record lib |
|
113f3912c7cb
util: Add Teal interface definition files
Kim Alvefur <zash@zash.se>
parents:
diff
changeset
|
2 format : function (string, ... : any) : string |
|
113f3912c7cb
util: Add Teal interface definition files
Kim Alvefur <zash@zash.se>
parents:
diff
changeset
|
3 end |
|
113f3912c7cb
util: Add Teal interface definition files
Kim Alvefur <zash@zash.se>
parents:
diff
changeset
|
4 return lib |