Subject: bug#34860: closed (Re: bug#34860: Probing broken symlinks always involves errors)

From: [email-masked] (GNU bug Tracking System)
Date: Sun, 30 Jun 2019 19:55:02 +0000

Your bug report

#34860: Probing broken symlinks always involves errors

which was filed against the guile package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
34860: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=34860
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#34860: Probing broken symlinks always involves errors
From: Ludovic Courtès <[email-masked]>
To: Tim Gesthuizen <[email-masked]>
Cc: Mark H Weaver <[email-masked]>, [email-masked]
Date: Sun, 30 Jun 2019 21:54:04 +0200
List-Id: <debbugs-submit.debbugs.gnu.org>

Hi Tim,

Tim Gesthuizen <[email-masked]> skribis:

> Mark H Weaver writes:
>> Anyway, I'm inclined to simply suggest using 'false-if-exception'.
>>
>> What do you think?
>
> I'm fine with this solution. My point was more about lowering the entry
> barrier for beginners than performance.
> If the change breaks ABI it is probably just not worth it.
>
> From my point of view we can close the ticket unless you want to keep it
> open until the documentation for stat is fixed.

Commit 63f54a7bc6adbc0f1b397872fb7eb96e84967ff1 updates the manual to
document the optional parameter of ‘stat’.

I think we can close the bug now.  :-)

Thanks,
Ludo’.

Subject: Probing broken symlinks always involves errors
From: Tim Gesthuizen <[email-masked]>
To: [email-masked]
Date: Thu, 14 Mar 2019 20:50:57 +0100
List-Id: <debbugs-submit.debbugs.gnu.org>

Hi,
I wrote a little application that tries to probe whether a symlink
exists. The `stat` function has an undocumented optional parameter that
lets stat return #f when the file does not exist. With this argument one
can probe for any files excluding broken symlinks.
lstat does not offer this argument. Therefore I needed to use
guard-expressions around lstat to probe for broken symlinks.

So probing broken symlinks relies on errors in the control flow and is
not straight forward. Maybe we should add the optional argument that
`stat` has and document the arguments for both commands.

I am using guile 2.2.4.

Tim.