mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2024-12-25 04:14:06 +00:00
linux: Print all siginfo structs on ChildSignal
I noticed this questionable loop that never loops in CL:1357700. Purely guessing as to what it was supposed to do -- I have not tested this codepath. TEST=cargo check Change-Id: I4560b80f080112a78adf440a663341f4fb0f1070 Reviewed-on: https://chromium-review.googlesource.com/1359010 Commit-Ready: David Tolnay <dtolnay@chromium.org> Tested-by: David Tolnay <dtolnay@chromium.org> Reviewed-by: Stephen Barber <smbarber@chromium.org>
This commit is contained in:
parent
35bac991e6
commit
f503276291
1 changed files with 9 additions and 12 deletions
21
src/linux.rs
21
src/linux.rs
|
@ -933,19 +933,16 @@ fn run_control(
|
|||
}
|
||||
Token::ChildSignal => {
|
||||
// Print all available siginfo structs, then exit the loop.
|
||||
loop {
|
||||
let result = sigchld_fd.read().map_err(Error::SignalFd)?;
|
||||
if let Some(siginfo) = result {
|
||||
error!(
|
||||
"child {} died: signo {}, status {}, code {}",
|
||||
siginfo.ssi_pid,
|
||||
siginfo.ssi_signo,
|
||||
siginfo.ssi_status,
|
||||
siginfo.ssi_code
|
||||
);
|
||||
}
|
||||
break 'poll;
|
||||
while let Some(siginfo) = sigchld_fd.read().map_err(Error::SignalFd)? {
|
||||
error!(
|
||||
"child {} died: signo {}, status {}, code {}",
|
||||
siginfo.ssi_pid,
|
||||
siginfo.ssi_signo,
|
||||
siginfo.ssi_status,
|
||||
siginfo.ssi_code
|
||||
);
|
||||
}
|
||||
break 'poll;
|
||||
}
|
||||
Token::CheckAvailableMemory => {
|
||||
// Acknowledge the timer.
|
||||
|
|
Loading…
Reference in a new issue