summaryrefslogtreecommitdiffstats
path: root/src/basic/hostname-util.c
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2015-07-28 04:36:36 +0200
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2015-08-06 02:49:21 +0200
commitae691c1d9382995ea7e28317f5c37023229c27ee (patch)
tree62ecbb70b83af41c523969a33c98efddef4eba35 /src/basic/hostname-util.c
parenthostnamectl: allow trailing dot on fqdn (diff)
downloadsystemd-ae691c1d9382995ea7e28317f5c37023229c27ee.tar.xz
systemd-ae691c1d9382995ea7e28317f5c37023229c27ee.zip
hostname-util: get rid of unused parameter of hostname_cleanup()
All users are now setting lowercase=false.
Diffstat (limited to 'src/basic/hostname-util.c')
-rw-r--r--src/basic/hostname-util.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/basic/hostname-util.c b/src/basic/hostname-util.c
index 21fae89fd0..95d9c3dd83 100644
--- a/src/basic/hostname-util.c
+++ b/src/basic/hostname-util.c
@@ -105,7 +105,7 @@ bool hostname_is_valid(const char *s, bool relax) {
return true;
}
-char* hostname_cleanup(char *s, bool lowercase) {
+char* hostname_cleanup(char *s) {
char *p, *d;
bool dot;
@@ -119,7 +119,7 @@ char* hostname_cleanup(char *s, bool lowercase) {
*(d++) = '.';
dot = true;
} else if (hostname_valid_char(*p)) {
- *(d++) = lowercase ? tolower(*p) : *p;
+ *(d++) = *p;
dot = false;
}
@@ -185,7 +185,7 @@ int read_hostname_config(const char *path, char **hostname) {
truncate_nl(l);
if (l[0] != '\0' && l[0] != '#') {
/* found line with value */
- name = hostname_cleanup(l, false);
+ name = hostname_cleanup(l);
name = strdup(name);
if (!name)
return -ENOMEM;