[Ecls-list] Potential problem with streams and EXT:RUN-PROGRAM

Goffioul Michael goffioul at imec.be
Tue May 17 04:35:02 UTC 2005


Hi,

During a few days, I fought with a problem I had with my matlab-embedded-ECL: the
symptom was a stream error after a call to EXT:RUN-PROGRAM, but it often happen
in an unpredictable way.

Looking at the code of that function, I realized that the standard handles are
duplicated, but this doesn't take into account the actual value of the variables
*standard-input/output* and the like. This means that if you redefine the LISP
standard input/outputs (which is my case), ext:run-program doesn't take that into
account.

In my particular case, the problem was that :error is T by default, such that the
child program got a duplicated handle of stderr. In the context of MATLAB, writing
to that handle produced errors (it's still unclear why this happen).

I don't know if it's a bug, but I just wanted to point this potential source of
problem, especially when you start to embed ECL.

Bye.
Michael.




More information about the ecl-devel mailing list