[Parted-maintainers] Bug#311664: parted: still broken with udev and devfs.rules

Sven Luther Sven Luther <sven.luther@wanadoo.fr>, 311664@bugs.debian.org
Thu, 2 Jun 2005 17:34:28 +0200


On Thu, Jun 02, 2005 at 03:44:08PM +0100, Colin Watson wrote:
> Package: parted
> Version: 1.6.21-1
> Severity: normal
> Tags: patch
> 
> (Originally noticed as
> https://bugzilla.ubuntu.com/show_bug.cgi?id=11426)
> 
> parted still breaks with udev and devfs.rules. Sorry I didn't notice
> this earlier; I looked at this line in libparted/linux.c:
> 
>         if (_have_devfs() && !strcmp (dev->path + path_len - 5, "/disc")) {
> 
> ... and it looked sufficiently similar to what I'd done earlier that I
> didn't notice that the test was &&, not ||. (Of course, || would be
> wrong too, since the code inside that if branch assumes that the strcmp
> matched.)
> 
> I suggest the attached patch. The _have_devfs() test is basically
> pointless; the traditional Linux device naming scheme doesn't have any
> devices that end with "/disc", so you might as well just test for that
> unconditionally.

Ok, thanks will apply. Need to package 1.6.22 too anyway.

BTW, it would be nice to upload ubuntu's gparted to debian too.

Friendly,

Sven Luther