summaryrefslogtreecommitdiff
path: root/src/hostname.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/hostname.c')
-rw-r--r--src/hostname.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/hostname.c b/src/hostname.c
index 082c89143..0abe64e21 100644
--- a/src/hostname.c
+++ b/src/hostname.c
@@ -100,7 +100,7 @@ main (int argc, char **argv)
/* Set hostname to operand. */
char const *name = argv[optind];
if (sethostname (name, strlen (name)) != 0)
- error (EXIT_FAILURE, errno, _("cannot set name to `%s'"), name);
+ error (EXIT_FAILURE, errno, _("cannot set name to %s"), quote (name));
#else
error (EXIT_FAILURE, 0,
_("cannot set hostname; this system lacks the functionality"));