OSDN Git Service
_device_unregister: check for unregistering the same device twice
_device_unregister() can get called 2 times for the same device if
a libparted user explictly removes the device from the cache using
ped_device_cache_remove(), it gets called and it then becomes the
user's responsibility to free the PedDevice by calling
ped_device_destroy(). ped_device_destroy() will then call
_device_unregister() a second time with the same device, so if the
device is not found in the list, do nothing.
* libparted/device.c(_device_unregister): Check for unregistering
the same device twice.
Reported by Jan Stodola in <http://bugzilla.redhat.com/568346>.