delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/07/19/19:04:11

Sender: nate AT cartsys DOT com
Message-ID: <35B2598C.94198835@cartsys.com>
Date: Sun, 19 Jul 1998 13:39:40 -0700
From: Nate Eldredge <nate AT cartsys DOT com>
MIME-Version: 1.0
To: Gerhard Gruber <sparhawk AT eunet DOT at>
CC: djgpp AT delorie DOT com
Subject: Re: read stderr
References: <01bdb1c5$1f278800$0a1f1bc4 AT default> <6oont0$rt2$2 AT news DOT luth DOT se> <35b568ae DOT 3265071 AT news DOT Austria DOT EU DOT net>

Gerhard Gruber wrote:
> 
> Destination: ams AT ludd DOT luth DOT se (Martin Str|mberg)
> From: Gruber Gerhard
> Group: comp.os.msdos.djgpp
> Date: 17 Jul 1998 23:48:48 GMT:
> 
> >Jorge Ivan Meza Martinez (jimeza AT usa DOT net) wrote:
> >: I use system to launch a child program,
> >: it generates stdout and stderr,
> >: I am interested in take this data to be shown in my program,
> >: how can I do that in a portable way ?
> >
> >Umh; how about redirecting it to a file?
> 
> That would be portable, but rather ugly. :) Also this means that you have to
> wait until the other program is finished and you can't launch programs that
> require interaction. I'd also be interested in how to doing this. Hmmm.
> Probably the author of RHIDE knows something because he did this there.

That would need multitasking, which is highly non-trivial to implement
under DOS.  In what way does RHIDE do this?  AFAIK, it either shows the
stderr of a program (like GCC), which you can do by dup2'ing fd 2 to a
file and displaying that, or it shells out, which is a simple case of
spawn.
-- 

Nate Eldredge
nate AT cartsys DOT com


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019