wrap SIGINFO in ifdef
This commit is contained in:
+7
-2
@@ -104,11 +104,13 @@ sigchld_handler(int sig)
|
||||
child_terminated = 1;
|
||||
}
|
||||
|
||||
#ifdef SIGINFO
|
||||
static void
|
||||
siginfo_handler(int sig)
|
||||
{
|
||||
siginfo_received = 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
static void
|
||||
client_alive_check(struct ssh *ssh)
|
||||
@@ -341,11 +343,14 @@ server_loop2(struct ssh *ssh, Authctxt *authctxt)
|
||||
debug("Entering interactive session for SSH2.");
|
||||
|
||||
if (sigemptyset(&bsigset) == -1 ||
|
||||
sigaddset(&bsigset, SIGCHLD) == -1 ||
|
||||
sigaddset(&bsigset, SIGINFO) == -1)
|
||||
sigaddset(&bsigset, SIGCHLD) == -1)
|
||||
error_f("bsigset setup: %s", strerror(errno));
|
||||
ssh_signal(SIGCHLD, sigchld_handler);
|
||||
#ifdef SIGINFO
|
||||
if (sigaddset(&bsigset, SIGINFO) == -1)
|
||||
error_f("bsigset setup: %s", strerror(errno));
|
||||
ssh_signal(SIGINFO, siginfo_handler);
|
||||
#endif
|
||||
child_terminated = 0;
|
||||
connection_in = ssh_packet_get_connection_in(ssh);
|
||||
connection_out = ssh_packet_get_connection_out(ssh);
|
||||
|
||||
Reference in New Issue
Block a user