From a09f0933bb80c52ec1bc30a1678cef7e999aeff9 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Fri, 13 Aug 2010 09:59:31 +0200 Subject: [PATCH] libblkid: wrong PT detection on RAID0 Reported-by: Yulia Kopkova Signed-off-by: Karel Zak --- shlibs/blkid/src/partitions/partitions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shlibs/blkid/src/partitions/partitions.c b/shlibs/blkid/src/partitions/partitions.c index 5597181a..d6abc203 100644 --- a/shlibs/blkid/src/partitions/partitions.c +++ b/shlibs/blkid/src/partitions/partitions.c @@ -833,7 +833,7 @@ int blkid_probe_is_covered_by_pt(blkid_probe pr, for (i = 0; i < nparts; i++) { blkid_partition par = &ls->parts[i]; - if (par->start + par->size > pr->size) { + if (par->start + par->size > (pr->size >> 9)) { DBG(DEBUG_LOWPROBE, printf("partition #%d overflows " "device (off=%lu size=%lu)\n", par->partno, par->start, par->size)); -- 2.39.5