hostnamectl: show hint when user try to set transient hostname but static hostname is already used
This commit is contained in:
@@ -233,4 +233,4 @@ static const char* const hostname_source_table[] = {
|
||||
[HOSTNAME_FALLBACK] = "fallback",
|
||||
};
|
||||
|
||||
DEFINE_STRING_TABLE_LOOKUP_TO_STRING(hostname_source, HostnameSource);
|
||||
DEFINE_STRING_TABLE_LOOKUP(hostname_source, HostnameSource);
|
||||
|
||||
@@ -11,7 +11,9 @@ typedef enum HostnameSource {
|
||||
_HOSTNAME_INVALID = -1,
|
||||
} HostnameSource;
|
||||
|
||||
const char* hostname_source_to_string(HostnameSource source);
|
||||
const char* hostname_source_to_string(HostnameSource source) _const_;
|
||||
HostnameSource hostname_source_from_string(const char *str) _pure_;
|
||||
|
||||
int sethostname_idempotent(const char *s);
|
||||
|
||||
int shorten_overlong(const char *s, char **ret);
|
||||
|
||||
Reference in New Issue
Block a user