From c8776e605edaa5a457148c2d7c3681b96b47b31d Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Sat, 18 Apr 2015 13:54:54 +0200 Subject: [PATCH] Bug fix: iso_image_report_system_area() did not show GPT partitions of size 0. --- libisofs/fs_image.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libisofs/fs_image.c b/libisofs/fs_image.c index 9dc9a6a..e4eccef 100644 --- a/libisofs/fs_image.c +++ b/libisofs/fs_image.c @@ -4213,7 +4213,8 @@ int iso_analyze_gpt(IsoImage *image, IsoDataSource *src, int flag) start_block = iso_read_lsb64(part + 32); block_count = iso_read_lsb64(part + 40); flags = iso_read_lsb64(part + 48); - if (block_count < start_block) + if ((start_block == 0 && block_count == 0) || + block_count + 1 < start_block) continue; block_count = block_count + 1 - start_block; if (sai->gpt_req == NULL) {