[parted-devel] keeping partitions in disk order

leslie.polzer at gmx.net leslie.polzer at gmx.net
Mon Aug 28 10:15:04 UTC 2006


On Sun, Aug 27, 2006 at 11:14:49PM -0500, Andrew Gaffney wrote:

> I traced the code down even farther to msdos_partition_enumerate() in
> libparted/labels/dos.c. I found the following code:
>
>         /* don't re-number a primary partition */ if (part->num != -1
>         && part->num <= 4) return 1;
>
> Looking around, I found something similar in sun_partition_enumerate()
> in libparted/labels/sun.c:
>
>         /* never change the partition numbers */ if (part->num != -1)
>         return 1;
>
> Anyone know why these are here?
libparted tries to preserve disk numbering as much as possible.

  Leslie

-- 
gpg --keyserver pgp.mit.edu --recv-keys DD4EBF83
http://nic-nac-project.de/~skypher/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.alioth.debian.org/pipermail/parted-devel/attachments/20060828/115e9cad/attachment.pgp


More information about the parted-devel mailing list