how process in background can kill itself after logout (BSD unix).

Cesar Quiroz quiroz at cs.rochester.edu
Wed Jan 30 15:32:25 AEST 1991


One more:  check for getppid()==1.  You turn into a child of init
when your natural parent has left for good.   Doesn't work if your
parent is waiting on you, rather than dying on logout itself.  Of
course, then *it* could be checking for its parent turning into
init.
-- 
                                      Cesar Augusto Quiroz Gonzalez
                                      Department of Computer Science
                                      University of Rochester
                                      Rochester,  NY 14627



More information about the Comp.unix.programmer mailing list