summaryrefslogtreecommitdiff
path: root/swap.c
diff options
context:
space:
mode:
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 174ce1dc0..bd49e1ea2 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;