Newsgroups: comp.sys.sgi Path: utzoo!censor!geac!alias!dino!chk From: chk%alias@csri.toronto.edu (C. Harald Koch) Subject: patch for X11R4 version of XDM Message-ID: <1990Nov27.213113.8766@alias.uucp> Sender: chk@dino.alias.uucp Reply-To: chk%alias@csri.toronto.edu (C. Harald Koch) Organization: Alias Research, Inc. Toronto ON Canada Date: 27 Nov 90 21:27:07 GMT It turns out that the patches I mentioned previously are very simple; I forgot that I had figured out an easy preliminary fix. For those of you who need to get X terminals working under XDMCP, I submit the following. This enables support for XDMCP at the expense of disabling support for the Xservers file. I am working on a proper fix, but it is low on my list of priorities. Basically, the fix is to call WaitForSomething() instead of WaitForChild() on sgi machines. Normally, the code there will also process dead children (necessary for Xservers support) but the code also relies heavily on BSD signal semantics, and fails on SysV machines. SIGCHLD is ignored to prevent zombies from building up and filling your process table; otherwise this is a problem because the children are never reaped. Use at your own risk. :-) ----------Cut-Here----------------------------- *** dm.c.orig Tue Oct 16 15:39:41 1990 --- dm.c Wed Oct 24 15:17:11 1990 *************** *** 111,117 **** ScanServers (); StartDisplays (); (void) signal (SIGHUP, RescanNotify); ! #ifndef SYSV (void) signal (SIGCHLD, ChildNotify); #endif while (AnyWellKnownSockets() || AnyDisplaysLeft ()) --- 122,130 ---- ScanServers (); StartDisplays (); (void) signal (SIGHUP, RescanNotify); ! #ifdef SYSV ! (void) signal (SIGCHLD, SIG_IGN); ! #else (void) signal (SIGCHLD, ChildNotify); #endif while (AnyWellKnownSockets() || AnyDisplaysLeft ()) *************** *** 121,127 **** RescanServers (); Rescan = 0; } ! #ifdef SYSV WaitForChild (); #else WaitForSomething (); --- 134,140 ---- RescanServers (); Rescan = 0; } ! #if defined(SYSV) && !defined(sgi) WaitForChild (); #else WaitForSomething (); -- C. Harald Koch VE3TLA Alias Research, Inc., Toronto ON Canada chk%alias@csri.utoronto.ca chk@gpu.utcs.toronto.edu chk@chk.mef.org "Open the Zamboni! We're coming out!" - Kathrin Garland and Anson James, 2299