[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug-tar] tar-1.25: test 39 fails on FreeBSD
From: |
Eric Blake |
Subject: |
Re: [Bug-tar] tar-1.25: test 39 fails on FreeBSD |
Date: |
Tue, 23 Nov 2010 14:15:56 -0700 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.12) Gecko/20101103 Fedora/1.0-0.33.b2pre.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.6 |
[moving to bug-gnulib]
On 11/23/2010 02:03 PM, Paul Eggert wrote:
> On 11/23/10 08:16, Joerg Schilling wrote:
>
>> The POSIX standard requires errno to be ELOOP in this case.
>
> Quite right. And I see that this incompatibility is not
> fixed in FreeBSD 9-current, at least according to the
> published manual page. Christian, would you please report this
> to the FreeBSD folks, if they don't know about it already?
>
> Christian's workaround is pretty easy, so I installed this:
> +++ b/src/extract.c
> @@ -609,6 +609,9 @@ maybe_recoverable (char *file_name, bool regular, bool
> *interdir_made)
> switch (e)
> {
> case ELOOP:
> + /* With open ("symlink", O_NOFOLLOW|...), POSIX says errno == ELOOP,
> + but FreeBSD through at least 8.1 uses errno == EMLINK. */
> + case EMLINK:
Should we instead patch gnulib's open() module to work around this bug,
so that tar can just rely on the gnulib module for POSIX semantics
instead of having to copy this workaround into all clients?
At any rate, this should be documented in gnulib's list of portability
pitfalls.
--
Eric Blake address@hidden +1-801-349-2682
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- Re: [Bug-tar] tar-1.25: test 39 fails on FreeBSD,
Eric Blake <=