X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=-2.0 required=5.0 	tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,SARE_FREE_WEBM_LAPOSTE
X-Spam-Check-By: sourceware.org
Message-ID: <4B89A29B.9040901@laposte.net>
Date: Sat, 27 Feb 2010 23:54:19 +0100
From: Cyrille Lefevre <cyrille.lefevre-lists@laposte.net>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.8.1.3) Gecko/20070326 Thunderbird/2.0.0.0 Mnenhy/0.7.5.666
MIME-Version: 1.0
To: cygwin@cygwin.com
Subject: Re: test for hard links always fail with pdksh
References: <4B8618EE.2070807@columbus.rr.com>  <20100225120506.GO5683@calimero.vinschen.de> <20100225154448.GB29140@ednor.casa.cgf.cx>
In-Reply-To: <20100225154448.GB29140@ednor.casa.cgf.cx>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: quoted-printable
X-me-spamlevel: not-spam
X-me-spamrating: 36.000000
X-me-spamcause:  OK, (-100)(0000)gggruggvucftvghtrhhoucdtuddrvdeltddrgeelucetggdotefuucfrrhhofhhilhgvmecuoehnohhnvgeqnecuuegrihhlohhuthemuceftddtnecuucdlqddutddtmd
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com


Christopher Faylor a =C3=A9crit :
> On Thu, Feb 25, 2010 at 01:05:06PM +0100, Corinna Vinschen wrote:
>> On Feb 25 01:30, Paul McFerrin wrote:
>>> A new wrinkle with hard links.  If you are testing for them in
>>> pdksh, they will always fail.  I.E.:
>>>
>>>    if test -L links/$filename.$inumb
>>>    then :
>>>    else
>>>       ln $filename $filename.$inumb
>>>    fi
>>>
>>> The above test will always fail and thus will always attempt to
>>> re-create the hard link.
>> $ man test
>>
>> test -L tests for symbolic links, not for hardlinks.
>=20
> So both the program and the documentation are wrong???  Who'd have though=
t it?

!!!

man ksh

        test expression
        [ expression ]
                -h file              file is a symbolic link.
                -L file              file is a symbolic link.

Regards,

Cyrille Lefevre
--=20
mailto:Cyrille.Lefevre-lists@laposte.net



--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

