Trying to build OpenSSH-2.1.0 on HP-UX 10.20

Tom Bertelson tbert at abac.com
Thu May 11 22:21:56 EST 2000


Lutz Jaenicke wrote:
> 
> And on we go :-(
> 
> I can now start the ssh2 client, but when connecting to the ssh server
> in Protocol 2 mode:
> 
> serv01 174: /usr/local/openssh/bin/ssh -2 -p 24 serv01
> jaenicke at serv01's password:
> Last login: Thu May 11 12:42:30 2000 from serv01.aet.tu-co
> 
> Pid 8011 received a SIGSEGV for stack growth failure.
> Possible causes: insufficient memory or swap space,
> or stack size exceeded maxssiz.
> Connection to serv01 closed by remote host.
> Connection to serv01 closed.
> 
> I receive a core dump, but it does not call me too much:
> (gdb) backtrace
> #0  0xc013ede8 in _sigvector () from /usr/lib/libc.1
> #1  0xc0148dd4 in signalvector () from /usr/lib/libc.1
> #2  0xc0148c74 in signal () from /usr/lib/libc.1
> #3  0xe51c in sigchld_handler2 ()
> #4  <signal handler called>
> #5  debug (fmt=0x0) at log.c:60
> #6  0xc013ede8 in _sigvector () from /usr/lib/libc.1

I had the same problem with AIX.  It seems that the SIGCHLD handler
immediately re-calls itself unless the dead process is first reaped.

This fixes it for me:
--- serverloop.c.orig	Wed May 10 14:34:00 2000
+++ serverloop.c	Thu May 11 08:17:17 2000
@@ -85,7 +85,6 @@
 	int save_errno = errno;
 	debug("Received SIGCHLD.");
 	child_terminated = 1;
-	signal(SIGCHLD, sigchld_handler2);
 	errno = save_errno;
 }
 
@@ -640,6 +639,7 @@
 			while ((pid = waitpid(-1, &status, WNOHANG)) > 0)
 				session_close_by_pid(pid, status);
 			child_terminated = 0;
+			signal(SIGCHLD, sigchld_handler2);
 		}
 		channel_after_select(&readset, &writeset);
 		process_input(&readset);





More information about the openssh-unix-dev mailing list