summaryrefslogtreecommitdiff
path: root/src/journal/sd-journal.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-10-22 23:20:59 +0200
committerLennart Poettering <lennart@poettering.net>2014-10-22 23:22:47 +0200
commitaffcf189153714f0de4d0986d18e2bc1b35c1b20 (patch)
treeb7e0c74332eda32a24962b206d3a7a66dd33cfb6 /src/journal/sd-journal.c
parent505e77caa5cafce27b0dbfcf23e9b28315d167ae (diff)
machine: validate machine names using machine_name_is_valid() instead of string_is_safe()
After all, we know have this as generic validator, so let's be correct and use it wherver applicable.
Diffstat (limited to 'src/journal/sd-journal.c')
-rw-r--r--src/journal/sd-journal.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/journal/sd-journal.c b/src/journal/sd-journal.c
index daa04ac4fa..ac57f4f6f8 100644
--- a/src/journal/sd-journal.c
+++ b/src/journal/sd-journal.c
@@ -1735,7 +1735,7 @@ _public_ int sd_journal_open_container(sd_journal **ret, const char *machine, in
assert_return(machine, -EINVAL);
assert_return(ret, -EINVAL);
assert_return((flags & ~(SD_JOURNAL_LOCAL_ONLY|SD_JOURNAL_SYSTEM)) == 0, -EINVAL);
- assert_return(filename_is_safe(machine), -EINVAL);
+ assert_return(machine_name_is_valid(machine), -EINVAL);
p = strappenda("/run/systemd/machines/", machine);
r = parse_env_file(p, NEWLINE, "ROOT", &root, "CLASS", &class, NULL);