From 6300a80c8466fc7297253cba91bb99994fa4e5c8 Mon Sep 17 00:00:00 2001 From: Christian Kellner Date: Sun, 27 Feb 2022 16:20:43 +0100 Subject: [PATCH] util/udev: fix path for udev device inhibitor The udev inhibitor rules are checking for `device-$major:$minor` but we created them with `f"device-{major}-{minor}"`. So they did indeed not actually work. Fix that. --- osbuild/util/udev.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osbuild/util/udev.py b/osbuild/util/udev.py index 6236ce45..b72de08c 100644 --- a/osbuild/util/udev.py +++ b/osbuild/util/udev.py @@ -53,7 +53,7 @@ class UdevInhibitor: @classmethod def for_device(cls, major: int, minor: int, lockdir=LOCKDIR): """Inhibit a device given its major and minor number""" - path = pathlib.Path(lockdir, f"device-{major}-{minor}") + path = pathlib.Path(lockdir, f"device-{major}:{minor}") ib = cls(path) ib.inhibit() return ib