The side effect of this bug is that wipefs(8) does not report LUKS...
Signed-off-by: Karel Zak <kzak@redhat.com>
int rc = 0;
struct blkid_chain *chn = blkid_probe_get_chain(pr);
- if (chn->flags & BLKID_SUBLKS_MAGIC) {
- if (magic && len)
- rc = blkid_probe_set_value(pr, "SBMAGIC", magic, len);
- if (!rc && offset)
+ if (magic && len && (chn->flags & BLKID_SUBLKS_MAGIC)) {
+ rc = blkid_probe_set_value(pr, "SBMAGIC", magic, len);
+ if (!rc)
rc = blkid_probe_sprintf_value(pr, "SBMAGIC_OFFSET",
"%llu", offset);
}