Path: utzoo!censor!geac!torsqnt!news-server.csri.toronto.edu!cs.utexas.edu!usc!zaphod.mps.ohio-state.edu!math.lsa.umich.edu!rphroy!trux!car From: car@trux.UUCP (Chris Rende) Newsgroups: comp.unix.wizards Subject: How to set control tty (Sys5) Message-ID: <483@trux.UUCP> Date: 5 Jul 90 17:56:50 GMT Organization: Central Cartage, Sterling Hgts., MI Lines: 23 I need to run a program via CRON(1M). However, the program aborts (presumably) because it cannot open it's control tty (/dev/tty). Running it in background (with &) works, and so does "nohup fussy &". I'd like to write a program which establishes a control tty and then spawns the fussy program. However, I can't figure/find out how to set the control tty. I read in TERMIO(7) something like "The first terminal file that gets opened becomes the control terminal". When I wrote a program that disassociates itself from the control terminal and then does a "fd=open("/dev/ttyi00",O_RDWR);" it didn't work. I.e, a "ps -ef" shows "?" for the control tty. Any help would be appreciated. Thanks, car. -- Christopher A. Rende Central Cartage (Nixdorf/Pyramid/SysVR2/BSD4.3) uunet!edsews!rphroy!trux!car Multics,DTSS,Unix,Shortwave,Scanners,StarTrek trux!car@uunet.uu.net Minix 1.2,PC/XT,Mac+,TRS-80 Model I,1802 ELF "I don't ever remember forgetting anything." - Chris Rende