Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!um-math!sharkey!cfctech!teemc!hpftc!zardoz!henry.jpl.nasa.gov!elroy.jpl.nasa.gov!usc!bloom-beacon!primerd!hobbiton!fieland From: fieland@hobbiton.prime.com Newsgroups: comp.lang.c Subject: Re: ttyname() - question Message-ID: <192700002@hobbiton> Date: 29 Aug 89 19:26:00 GMT References: <99@lkbpyr.UUCP> Lines: 27 Nf-ID: #R:lkbpyr.UUCP:-9900:hobbiton:192700002:000:490 Nf-From: hobbiton.prime.com!fieland Aug 29 15:26:00 1989 I can't answer your question. In fact, your program(s) didn't print out my tty on either the MIPS or my Sun 386i. I was able to get my tty on the mips with the program below, although the term returned was null when I executted the program on the SUn in a window. Notice the print format. Peggy #includemain() { char *term; char *ttyname(); term=ttyname(); printf("%s\n",term); test(); } test() { char *term; char *ttyname(); term=ttyname(); printf("%s\n",term); }