Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!think.com!mintaka!bloom-beacon!eru!hagbard!lunic!my!luth!d87-pjn From: d87-pjn@sm.luth.se (P-O Jacobson) Newsgroups: comp.windows.x Subject: Re: Help Requested with Xview's TTY Subwindows (WE NEED IT TOO) Message-ID: <1610@tau.sm.luth.se> Date: 24 May 91 10:33:11 GMT References: <76368@brunix.UUCP> Organization: University of Lulea, Sweden Lines: 41 demillo@porter.geo.brown.edu (Rob DeMillo) writes: >I am in the middle of authoring and X Application that I >had intended to use multiple TTY Subwindows on, but I have >ran into difficulty: We are in the coming few days supposed to complete a small X-program here on the university. A small problem has arised, tough: We can't find a proper way of opening some kind of a tty attached to a window, so that it later on can be used for stdin, stdout and stderr. Our confusion has lead us to the following UGLY solution: 1) Open an pty 2) fork() 3) execvp("xterm",args) where args includes "-S%c%c%d" where %c%c is the last two chars in the filename of the pty and %d is the number of the inherited filedescriptor. This gives us an hanging xshell process that we can't control, but we do get the tty we wanted to!! Our question is: How do we get the tty we want, and still be able to look our teachers in the eyes afterwards??? Any help is appreciated, the faster the better. The program is due on tuesday. :-( P.S we are working on a SUN station using X11R4 and the twm window manager P-O Jacobson (d87-pjn@sm.luth.se) and Hakan Hellberg (d86-hhg@sm.luth.se) ------------------------------------------------------------------------------- P-O Jacobson Internet : d87-pjn@sm.luth.se UUCP : {uunet,mcvax}!sunic.se!sm.luth.se!d87-pjn University of Lulea,Sweden. -------------------------------------------------------------------------------