Hi again, I think I've spotted the responsible source code fragment. If I haven't been misled by the hundreds of #ifdefs in the upstream source, the problematic function is
gvd/gnat/gexpect_tty.c:1579 : process_send_signal() In lines 1649-1653, it tries to get hold of the process group to signal, and stores the ioctl() return value into err, which is then only checked "#ifdef pfa", which is unset on Linux (it appears only in a few other #ifdef's, and I can't find a reference to it anywhere else). Now that the ioctl() is unchecked, gid may contain any- thing, as the variable is only defined, not initialized, and unfortunately it contains 1. Line 1719 then reverses the sign to -1, and finally line 1780 fires off the macro GVD_KILLPG(-gid, signo) which expands under Linux to kill(-(-gid), signo) which yields kill(-1, signo). [Responsible macro definition in gvd/gnat/syssignal.h] Removing the "#ifdef pfa" around the return value check should fix the problem, although that's likely only mending the symptoms, not the cause: The code in question has no support whatsoever for the case that the ioctl()ed FD is already closed, so maybe this should be detected and handled properly earlier. Regards, Jan PS: All line numbers are for the latest tarball - I haven't checked if the mentioned code has changed in CVS since then... -- Jan C. Nordholz <jckn at gmx dot net> -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]