summaryrefslogtreecommitdiffstats
path: root/fdisks/sfdisk.c
diff options
context:
space:
mode:
authorSami Kerola2013-07-07 21:54:16 +0200
committerKarel Zak2013-07-09 14:24:47 +0200
commitcdd834c37d94a37cd391c9498a3399015eb6380c (patch)
tree2d019f4769db4e036edcaffe6e121a6e030b6a34 /fdisks/sfdisk.c
parentMerge branch 'patch-1' of https://github.com/kernc/util-linux (diff)
downloadkernel-qcow2-util-linux-cdd834c37d94a37cd391c9498a3399015eb6380c.tar.gz
kernel-qcow2-util-linux-cdd834c37d94a37cd391c9498a3399015eb6380c.tar.xz
kernel-qcow2-util-linux-cdd834c37d94a37cd391c9498a3399015eb6380c.zip
sfdisk: make unhiding as complete as possible
It is unlikely anyone will ever need this, but I like idea commands being complete. The partition id's that can be unhide after this change are; Hidden HPFS/NTFS Hidden W95 FAT32 Hidden W95 FAT32 (LBA) Hidden W95 FAT16 (LBA) Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Diffstat (limited to 'fdisks/sfdisk.c')
-rw-r--r--fdisks/sfdisk.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fdisks/sfdisk.c b/fdisks/sfdisk.c
index 6efef4737..6b757a778 100644
--- a/fdisks/sfdisk.c
+++ b/fdisks/sfdisk.c
@@ -2992,7 +2992,8 @@ set_unhidden(struct disk_desc *z, char *pnam) {
pno = asc_to_index(pnam, z);
id = z->partitions[pno].p.sys_type;
- if (id == 0x11 || id == 0x14 || id == 0x16 || id == 0x17)
+ if (id == 0x11 || id == 0x14 || id == 0x16 || id == 0x17 ||
+ id == 0x17 || id == 0x1b || id == 0x1c || id == 0x1e)
id -= 0x10;
else
errx(EXIT_FAILURE, _("partition %s has id %x and is not hidden"), pnam, id);