[Openmcl-devel] `run-program' path search broken

Gary Byers gb at clozure.com
Sat Jun 2 00:27:03 PDT 2007

I (somehow) managed to miss this message twice, both with and
without a subject ...  sorry.

My first reaction was to suggest that RUN-PROGRAM's first argument
be changed from "a string or pathname ..." to "a string ... used
in combination with the value of PATH to identify an executable file".
That might be a little too restrictive, and it might be better to
just say that 'any translation of the program argument into something
that the OS can use takes place as if *DEFAULT-PATHNAME-DEFAULTS*
was bound to #p""'.

This would mean that if anyone's (intentionally) doing something

(let* ((*default-pathname-defaults* #p"/usr/local/bin/"))
   (run-program "ls" ...))

they'd have to instead do

(let* ((*default-pathname-defaults* #p"/usr/local/bin/"))
   (run-program (merge-pathnames "ls") ...))

That doesn't seem too onerous.

The MERGE-PATHNAMES that currently happens during "translation to
something that the OS can use" isn't entirely intentional, but
it leads to a situation where two referentially opaque things
(PATH and *DEFAULT-PATHNAME-DEFAULTS*) exert influence over what
happens, and it's not surprising that that leads to bizarre

On Sat, 26 May 2007, Scott L. Burson wrote:

> Sigh -- supplying subject line for previous message.  Sorry.
> -- Scott
> _______________________________________________
> Openmcl-devel mailing list
> Openmcl-devel at clozure.com
> http://clozure.com/mailman/listinfo/openmcl-devel

More information about the Openmcl-devel mailing list