[Parted-maintainers] Bug#586682: libparted: partitions created with ped_device_new_from_store() make libparted crash on _done()

Jérémie Koenig jk at jk.fr.eu.org
Mon Jun 21 16:04:38 UTC 2010

Package: libparted0debian1
Version: 2.2-5
Severity: normal
Tags: patch
User: jk at jk.fr.eu.org
Usertags: gsoc2010
User: debian-hurd at lists.debian.org
Usertags: hurd

(^^^ hope this works, will fix it if not.)

Hello, thanks for maintaining parted.

On Hurd, libparted devices can be created directly from "store" objects
through the hurd-specific ped_device_new_from_store() function.

Such devices don't get registered into linked list and have a
non-initialized 'next' field. A later call to ped_device_destroy() will
make _device_unregister() mangle the mailing list as a result.
A crash will result the next time the list is used, for instance on exit
when destroying all devices.

For what it's worth, ped_device_new_from_store() is used for the
(preliminary) user-space partitions support in Hurd's libstore, which
will probably be needed for debian-installer.

The attached patch makes _device_unregister() do nothing if the device
was not found in the list.

Jeremie Koenig <jk at jk.fr.eu.org>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: parted-non-registered-device.diff
Type: text/x-diff
Size: 411 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/parted-maintainers/attachments/20100621/597a3513/attachment.diff>

More information about the Parted-maintainers mailing list