chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
sd-login: use the same code for verfiying machine names everywhere
[elogind.git]
/
src
/
libsystemd
/
sd-login
/
sd-login.c
diff --git
a/src/libsystemd/sd-login/sd-login.c
b/src/libsystemd/sd-login/sd-login.c
index 375a5388aa73d37124a47b4b4b1ff2d66e47b058..d1478ddb785a43703dd61dc479d616306a9e3a3b 100644
(file)
--- a/
src/libsystemd/sd-login/sd-login.c
+++ b/
src/libsystemd/sd-login/sd-login.c
@@
-770,7
+770,7
@@
_public_ int sd_machine_get_class(const char *machine, char **class) {
const char *p;
int r;
const char *p;
int r;
- assert_return(
filename_is_safe
(machine), -EINVAL);
+ assert_return(
machine_name_is_valid
(machine), -EINVAL);
assert_return(class, -EINVAL);
p = strappenda("/run/systemd/machines/", machine);
assert_return(class, -EINVAL);
p = strappenda("/run/systemd/machines/", machine);