Mail Archives: djgpp/2002/07/09/10:31:11
"Martin Str|mberg" <ams AT speedy DOT ludd DOT luth DOT se> wrote in message
news:1026169200 DOT 645701 AT queeg DOT ludd DOT luth DOT se...
> Alex Oleynikov <alex AT compuweigh DOT com> wrote:
> : I have a question about strange implications of using the redir utility.
> : To start the main application I use the following command line:
> : redir -e COM3 app.exe
>
> : The COM3 has a serial printer attached to it, which is used by the main
> : program as an audit trail printer to print legal information about the
> : user's actions (I use PMCOM to communicate with serial devices).
> : Now, everything is OK up until the moment when something is output to
the
> : stderr stream. From that moment on the serial printer becomes invisible
to
> : my program - nothing gets printed when the program sends it to COM3.
Still,
> : the stderr output intercepted by redir gets down to the printer without
any
> : problems.
>
> : It looks like redir keeps that COM-port open all the time after the
first
> : moment it was accessed by this utility and this prevents the main
program
> : from getting access to it.
>
> : Does anyone have any thoughts on this matter?
>
> Are you sure that the output doesn't come, but later? (stdout is
> buffered.)
>
Yes, I am sure. Actually, I am not using stdout, but rather send data to
COM3 directly using PMCOM library calls.
>
> Right,
>
> MartinS
- Raw text -