summaryrefslogtreecommitdiff
path: root/swap.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-05-16 18:13:58 +0200
committerLennart Poettering <lennart@poettering.net>2010-05-16 18:13:58 +0200
commit8407a5d0183d9513349754f1eac86e2fdec8bd76 (patch)
tree23f0ef1f45dfb5a0d904f215973a062045547e0b /swap.c
parentd4e6a6f66b7b3c797a1446816b8512d82c92278f (diff)
swap: don't add mount links for swap devices
Diffstat (limited to 'swap.c')
-rw-r--r--swap.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/swap.c b/swap.c
index 174ce1dc0e..bd49e1ea2b 100644
--- a/swap.c
+++ b/swap.c
@@ -70,6 +70,9 @@ int swap_add_one_mount_link(Swap *s, Mount *m) {
m->meta.load_state != UNIT_LOADED)
return 0;
+ if (is_device_path(s->what))
+ return 0;
+
if (!path_startswith(s->what, m->where))
return 0;