Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!sdd.hp.com!hp-pcd!hpcvlx.cv.hp.com!porsche From: porsche@hpcvlx.cv.hp.com. (John Milton) Newsgroups: comp.sys.hp Subject: Re: Xterm HP-UX 7.03 and me Message-ID: <101950235@hpcvlx.cv.hp.com.> Date: 20 Jun 91 22:29:21 GMT References: <1991Jun13.111656.19463@doug.cae.wisc.edu> Organization: Hewlett-Packard Co., Corvallis, OR, USA Lines: 27 This is the result of a change to the 7.0 version of getpgrp2 to make it POSIX compliant. (Evidentally, MIT ran into this problem because it has been fixed in the R4 version of xterm.) In the version of xterm supplied with 7.0x, selecting the 'Send INT signal' item from the menu causes the following line to be executed: killpg(getpgrp(screen->pid), SIGINT); Which, after substituting for macro definitions, becomes: kill(-(getpgrp2(screen->pid)), SIGINT); In HP-UX 7.0 (and presumably any POSIX compliant OS) getpgrp2 fails if the current process (xterm) and the specified process (the shell) are not in the same session (which they aren't). Thus, when getpgrp2 fails, SIGINT is sent to init (-(-1)=1), forcing init to run level 0. The Release 4 version of xterm is supplied with HP-UX 8.0 and the code has been changed, sending the signal to the process id of the shell process instead of the shell's process group (it doesn't call getpgrp2). Until you upgrade to HP-UX 8.0 don't select the 'Send INT signal' item in the 'Main Options' menu. (Actually, you probably shouldn't select any of the send signal options because, for the reasons outlined above, the signal is sent to init rather than the shell's process group.) John "porsche is a two syllable word" Milton porsche@hp-pcd