mirror of
https://github.com/xcat2/xcat-core.git
synced 2025-06-21 05:25:32 +00:00
defect 4759: Fix the issue that ssl_listener used up all cpu.
This commit is contained in:
@ -1156,7 +1156,17 @@ until ($quit) {
|
||||
push @pendingconnections,$tconn;
|
||||
}
|
||||
} else {
|
||||
$bothwatcher->can_read(30);
|
||||
# if select returned with no ready fds, there might be udpctl broken.
|
||||
if (not $bothwatcher->can_read(30)) {
|
||||
# if the errno is 'bad fd', check the health of the udpctl
|
||||
if ($! == EBADF) {
|
||||
$udpwatcher->can_read(0);
|
||||
if ($! == EBADF) {
|
||||
# if udpctl cannot be read and said 'bad fd', remove it from $bothwatcher
|
||||
$udpalive = 0;$bothwatcher = IO::Select->new($listener);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (not $listenwatcher->can_read(0)) { # check for udpctl messages since
|
||||
# we have no listen to hear
|
||||
next;
|
||||
|
Reference in New Issue
Block a user