bug-parted
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Linux swap partitions set to type 0x83


From: Kenneth MacDonald
Subject: Linux swap partitions set to type 0x83
Date: Wed, 25 Jul 2007 12:54:25 +0100

parted 1.8.7 (git trunk seems to be the same)

The comparison of fs_type->name to "linux-swap" no longer catches Linux
swap partitions as they're called either "linux-swap(new)" or
"linux-swap(old)".  This means, at least in the DOS label code, creating
Linux swap partitions results in the system (type) byte in the partition
table defaulting to "0x83" (Linux) rather than "0x82" (Linux Swap).

I've fixed this by performing a match on the first ten characters of the
fs_type->name variable ("linux-swap" is ten characters long).

Find attached a patch for the following labels: bsd, dasd, dos, mac, rdb
and sun.  From what I can tell, the other labels either don't handle
Linux swap partitions or don't need to be changed (e.g. gpt simply looks
for a substring of "swap").

Cheers,

Kenny.

--
Desktop Services, IS Infrastructure, The University of Edinburgh


Attachment: parted-linux-swap.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]