projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
89106f0
)
6647 - use path_startswith("/dev") in cryptsetup (#6732)
author
ettavolt
<ettavolt@gmail.com>
Mon, 4 Sep 2017 13:36:52 +0000
(16:36 +0300)
committer
Lennart Poettering
<lennart@poettering.net>
Mon, 4 Sep 2017 13:36:52 +0000
(15:36 +0200)
For both key and partition paths.
src/cryptsetup/cryptsetup-generator.c
patch
|
blob
|
history
diff --git
a/src/cryptsetup/cryptsetup-generator.c
b/src/cryptsetup/cryptsetup-generator.c
index
9ecb6e3
..
613b018
100644
(file)
--- a/
src/cryptsetup/cryptsetup-generator.c
+++ b/
src/cryptsetup/cryptsetup-generator.c
@@
-129,7
+129,7
@@
static int create_disk(
if (!path_equal(uu, "/dev/null")) {
- if (
is_device_path(uu
)) {
+ if (
path_startswith(uu, "/dev/"
)) {
_cleanup_free_ char *dd = NULL;
r = unit_name_from_path(uu, ".device", &dd);
@@
-143,7
+143,7
@@
static int create_disk(
}
}
- if (
is_device_path(u
)) {
+ if (
path_startswith(u, "/dev/"
)) {
fprintf(f,
"BindsTo=%s\n"
"After=%s\n"