blkid: optional support for TYPE="fstype"
Adapted from patch created by T4ndeta <t4ndeta@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
diff --git a/util-linux/volume_id/ext.c b/util-linux/volume_id/ext.c
index 80c217f..b5194a7 100644
--- a/util-linux/volume_id/ext.c
+++ b/util-linux/volume_id/ext.c
@@ -65,10 +65,12 @@
volume_id_set_uuid(id, es->uuid, UUID_DCE);
dbg("ext: label '%s' uuid '%s'", id->label, id->uuid);
-// if ((le32_to_cpu(es->feature_compat) & EXT3_FEATURE_COMPAT_HAS_JOURNAL) != 0)
-// id->type = "ext3";
-// else
-// id->type = "ext2";
+#if ENABLE_FEATURE_BLKID_TYPE
+ if ((le32_to_cpu(es->feature_compat) & EXT3_FEATURE_COMPAT_HAS_JOURNAL) != 0)
+ id->type = "ext3";
+ else
+ id->type = "ext2";
+#endif
return 0;
}