From 2b51554ff59d1e5cbf8dd2db65d278b0202a9102 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Sat, 27 Jun 2026 03:52:05 +0900 Subject: refactor: fix compiler warnings and clippy warnings --- crates/shirabe-php-shim/src/stream.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'crates/shirabe-php-shim/src/stream.rs') diff --git a/crates/shirabe-php-shim/src/stream.rs b/crates/shirabe-php-shim/src/stream.rs index 606b202..98f0322 100644 --- a/crates/shirabe-php-shim/src/stream.rs +++ b/crates/shirabe-php-shim/src/stream.rs @@ -346,12 +346,12 @@ pub fn stream_select( // emit a warning for them. We skip them here, leaving them out of the ready set. let mut prepare = |set: &mut FdSet, resources: &[PhpResource]| { for resource in resources { - if let Some(fd) = resource.raw_fd() { - if (fd as usize) < FD_SETSIZE { - set.set(fd); - if fd + 1 > nfds { - nfds = fd + 1; - } + if let Some(fd) = resource.raw_fd() + && (fd as usize) < FD_SETSIZE + { + set.set(fd); + if fd + 1 > nfds { + nfds = fd + 1; } } } -- cgit v1.3.1