diff options
author | Richard W.M. Jones <rjones@redhat.com> | 2012-07-16 16:26:26 +0100 |
---|---|---|
committer | Richard W.M. Jones <rjones@redhat.com> | 2012-08-05 21:58:34 +0100 |
commit | 9a98a6e3dc85d840c5bf294410314c9a10c0bbe1 (patch) | |
tree | 1cb2c10ab32b326fbfc37096a09bae2555ff75a2 | |
parent | 97d326771491897f90f37db73325c5d06ab5f4e0 (diff) | |
download | libguestfs-9a98a6e3dc85d840c5bf294410314c9a10c0bbe1.tar.gz libguestfs-9a98a6e3dc85d840c5bf294410314c9a10c0bbe1.tar.xz libguestfs-9a98a6e3dc85d840c5bf294410314c9a10c0bbe1.zip |
virt-make-fs: Recognize "msdos" as a partition or filesystem type.
Set MBR partition type byte accordingly.
(cherry picked from commit 24b7979ea25cbe5f08494cc4580c1341e78e090e)
-rwxr-xr-x | tools/virt-make-fs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/tools/virt-make-fs b/tools/virt-make-fs index 5cb5101c..34471d70 100755 --- a/tools/virt-make-fs +++ b/tools/virt-make-fs @@ -431,8 +431,12 @@ eval { # Set the partition type byte if it's MBR and the filesystem # type is one that we know about. my $mbr_id; - if ($partition eq "mbr") { - if ($type =~ /^v?fat$/) { + if ($partition eq "mbr" || $partition eq "msdos") { + if ($type eq "msdos") { + # According to Wikipedia. However I have not actually + # tried this. + $mbr_id = 0x1; + } elsif ($type =~ /^v?fat$/) { $mbr_id = 0xb; } elsif ($type eq "ntfs") { $mbr_id = 0x7; |