[systemd-devel] [v3] udev: Expose new ISO9660 props from libblkid
Zeeshan Ali (Khattak)
zeeshanak at gnome.org
Sat Feb 16 17:21:27 PST 2013
From: "Zeeshan Ali (Khattak)" <zeeshanak at gnome.org>
v3: Encode all string using blkid_encode_string().
---
src/udev/udev-builtin-blkid.c | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/src/udev/udev-builtin-blkid.c b/src/udev/udev-builtin-blkid.c
index 56a05f5..bae4293 100644
--- a/src/udev/udev-builtin-blkid.c
+++ b/src/udev/udev-builtin-blkid.c
@@ -78,6 +78,22 @@ static void print_property(struct udev_device *dev, bool test, const char *name,
} else if (startswith(name, "PART_ENTRY_")) {
strscpyl(s, sizeof(s), "ID_", name, NULL);
udev_builtin_add_property(dev, test, s, value);
+
+ } else if (streq(name, "SYSTEM_ID")) {
+ blkid_encode_string(value, s, sizeof(s));
+ udev_builtin_add_property(dev, test, "ID_FS_SYSTEM_ID", s);
+
+ } else if (streq(name, "PUBLISHER_ID")) {
+ blkid_encode_string(value, s, sizeof(s));
+ udev_builtin_add_property(dev, test, "ID_FS_PUBLISHER_ID", s);
+
+ } else if (streq(name, "APPLICATION_ID")) {
+ blkid_encode_string(value, s, sizeof(s));
+ udev_builtin_add_property(dev, test, "ID_FS_APPLICATION_ID", s);
+
+ } else if (streq(name, "BOOT_SYSTEM_ID")) {
+ blkid_encode_string(value, s, sizeof(s));
+ udev_builtin_add_property(dev, test, "ID_FS_BOOT_SYSTEM_ID", s);
}
}
--
1.8.1.2
More information about the systemd-devel
mailing list