setpgrp question
Dan Mercer
mercer at ncrcce.StPaul.NCR.COM
Wed Dec 27 15:47:08 AEST 1989
In article <1989Dec24.222740.8645 at virtech.uucp> cpcahil at virtech.uucp (Conor P. Cahill) writes:
:In article <6863 at cbnewsh.ATT.COM>, skumar at cbnewsh.ATT.COM (swaminathan.ravikumar) writes:
:
:> By reading different sources I found out that a process can
:> break its control terminal by calling "setpgrp". I don't
:> understand this 100%. Why should the process lose the control
:> terminal? why do you need "setpgrp"?
:
:setpgrp() is one of the steps that should be executed by a daemon
:process at initialization time. It does disconnect the terminal from
:the controll tty and therefore should only be used by programs that
:no longer wish to be associated with a terminal.
For instance, in the telecommunications program PCOMM, patterned
closely after PROCOMM(tm), the input process originally generated
SIGHUP back to the controlling terminal when the dial-out line hung
up. I was one of the first to notice the problem, since I have
a personal daemon running in background that provides me special
services within vi. Adding a setpgrp() to the input routine cleared
the problem and was later added by a patch level.
The Token Ring NetBIOS software for the NCR Tower has the same problem
with nlogin, which allows login sessions across the ring.
--
Dan Mercer
Reply-To: mercer at ncrcce.StPaul.NCR.COM (Dan Mercer)
More information about the Comp.unix.questions
mailing list