filepath

Aaron Denney wnoise at ofb.net
Sun Dec 9 16:18:20 EST 2007


On 2007-12-09, Bryan O'Sullivan <bos at serpentine.com> wrote:
> Claus Reinke wrote:
>
>> ./foo and foo are not interchangeable:
>
> Yes, they are.
>
> What you have described is the behaviour of the Bourne shell when it
> parses a line and searches for a command.  If it sees a path component
> in a command name, it searches from either the filesystem root or the
> current directory.  Otherwise, it uses $PATH, which does not usually
> contain ".", for security reasons.

Actually, this is done by certain variants of the exec*() family of
system/library calls.

> As you can now imagine, this has no relation to how a Haskell program
> should be manipulating paths.

What, Haskell programs won't ever be manipulating paths of executables it
will be calling?

-- 
Aaron Denney
-><-



More information about the Libraries mailing list