[Top][All Lists]

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

Re: [PATCH] libparted: ignore zero-length devices

From: Jim Meyering
Subject: Re: [PATCH] libparted: ignore zero-length devices
Date: Sat, 20 Nov 2010 09:32:41 +0100

Otavio Salvador wrote:
> On Wed, Nov 17, 2010 at 1:14 PM, Colin Watson <address@hidden> wrote:
> ...
>> * libparted/arch/linux.c (_device_get_length): Return the value of
>> PARTED_TEST_DEVICE_LENGTH if set in the environment, strictly for use by
>> the test suite.
> ...
> The patch itself looks OK however as discussed at IRC I think that
> LD_PRELOAD could be used to override ioctl for the test case. This
> would avoid us to use getenv on it.

Good idea.
Thanks for the suggestion.

I too would prefer to avoid adding another getenv use in the library, and
using an LD_PRELOAD-replaced ioctl in the test would be an elegant way to
do that.  However, I didn't want to let that desire hold up this patch --
it's rare enough to receive a complete and impeccable patch (i.e., with
NEWS, a detailed ChangeLog entry *and* a test case).  It would have been
wrong to hold out for an additional "would be nice" change.

reply via email to

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