chore(deps): update rust crate spin to v0.12.1#2147
clippy macos-latest
22 warnings
Details
Results
| Message level | Amount |
|---|---|
| Internal compiler error | 0 |
| Error | 0 |
| Warning | 22 |
| Note | 0 |
| Help | 0 |
Versions
- rustc 1.96.0 (ac68faa20 2026-05-25)
- cargo 1.96.0 (30a34c682 2026-05-25)
- clippy 0.1.96 (ac68faa20c 2026-05-25)
Annotations
Check warning on line 46 in crates/shadowsocks-service/src/server/tcprelay.rs
github-actions / clippy macos-latest
large size difference between variants
warning: large size difference between variants
--> crates/shadowsocks-service/src/server/tcprelay.rs:43:1
|
43 | / enum RemoteStream {
44 | | Direct(OutboundTcpStream),
| | ------------------------- the second-largest variant contains at least 48 bytes
45 | | Proxied(OutboundProxyStream),
| | ---------------------------- the largest variant contains at least 1160 bytes
46 | | }
| |_^ the entire enum is at least 1160 bytes
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#large_enum_variant
= note: `#[warn(clippy::large_enum_variant)]` on by default
help: consider boxing the large fields or introducing indirection in some other way to reduce the total size of the enum
|
45 - Proxied(OutboundProxyStream),
45 + Proxied(Box<OutboundProxyStream>),
|
Check warning on line 80 in crates/shadowsocks-service/src/local/fake_dns/udp_server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/fake_dns/udp_server.rs:80:32
|
80 | return Err(io::Error::new(io::ErrorKind::Other, err));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
80 - return Err(io::Error::new(io::ErrorKind::Other, err));
80 + return Err(io::Error::other(err));
|
Check warning on line 151 in crates/shadowsocks-service/src/local/fake_dns/tcp_server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/fake_dns/tcp_server.rs:151:28
|
151 | return Err(io::Error::new(io::ErrorKind::Other, err));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
151 - return Err(io::Error::new(io::ErrorKind::Other, err));
151 + return Err(io::Error::other(err));
|
Check warning on line 133 in crates/shadowsocks-service/src/local/fake_dns/tcp_server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/fake_dns/tcp_server.rs:133:32
|
133 | return Err(io::Error::new(io::ErrorKind::Other, err));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
133 - return Err(io::Error::new(io::ErrorKind::Other, err));
133 + return Err(io::Error::other(err));
|
Check warning on line 984 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:984:32
|
984 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err)),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
984 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err)),
984 + .map_err(|err| io::Error::other(err)),
|
Check warning on line 975 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:975:50
|
975 | next.await.map_err(|err| io::Error::new(io::ErrorKind::Other, err))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
975 - next.await.map_err(|err| io::Error::new(io::ErrorKind::Other, err))
975 + next.await.map_err(|err| io::Error::other(err))
|
Check warning on line 971 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:971:50
|
971 | next.await.map_err(|err| io::Error::new(io::ErrorKind::Other, err))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
971 - next.await.map_err(|err| io::Error::new(io::ErrorKind::Other, err))
971 + next.await.map_err(|err| io::Error::other(err))
|
Check warning on line 922 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:922:61
|
922 | Err(..) => next.await.map_err(|err| io::Error::new(io::ErrorKind::Other, err)),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
922 - Err(..) => next.await.map_err(|err| io::Error::new(io::ErrorKind::Other, err)),
922 + Err(..) => next.await.map_err(|err| io::Error::other(err)),
|
Check warning on line 918 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:918:61
|
918 | Err(..) => next.await.map_err(|err| io::Error::new(io::ErrorKind::Other, err)),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
918 - Err(..) => next.await.map_err(|err| io::Error::new(io::ErrorKind::Other, err)),
918 + Err(..) => next.await.map_err(|err| io::Error::other(err)),
|
Check warning on line 886 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:886:36
|
886 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
886 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err))
886 + .map_err(|err| io::Error::other(err))
|
Check warning on line 879 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:879:36
|
879 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
879 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err))
879 + .map_err(|err| io::Error::other(err))
|
Check warning on line 488 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:488:36
|
488 | Err(err) => return Err(io::Error::new(io::ErrorKind::Other, err)),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
488 - Err(err) => return Err(io::Error::new(io::ErrorKind::Other, err)),
488 + Err(err) => return Err(io::Error::other(err)),
|
Check warning on line 338 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:338:40
|
338 | Err(err) => return Err(io::Error::new(io::ErrorKind::Other, err)),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
338 - Err(err) => return Err(io::Error::new(io::ErrorKind::Other, err)),
338 + Err(err) => return Err(io::Error::other(err)),
|
Check warning on line 332 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:332:32
|
332 | return Err(io::Error::new(io::ErrorKind::Other, err));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
332 - return Err(io::Error::new(io::ErrorKind::Other, err));
332 + return Err(io::Error::other(err));
|
Check warning on line 324 in crates/shadowsocks-service/src/local/dns/server.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/server.rs:324:32
|
324 | return Err(io::Error::new(io::ErrorKind::Other, err));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
324 - return Err(io::Error::new(io::ErrorKind::Other, err));
324 + return Err(io::Error::other(err));
|
Check warning on line 101 in crates/shadowsocks-service/src/local/dns/dns_resolver.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/dns_resolver.rs:101:32
|
101 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err)),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
101 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err)),
101 + .map_err(|err| io::Error::other(err)),
|
Check warning on line 88 in crates/shadowsocks-service/src/local/dns/dns_resolver.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/dns_resolver.rs:88:40
|
88 | ... last_err = io::Error::new(io::ErrorKind::Other, err);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
88 - last_err = io::Error::new(io::ErrorKind::Other, err);
88 + last_err = io::Error::other(err);
|
Check warning on line 79 in crates/shadowsocks-service/src/local/dns/dns_resolver.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks-service/src/local/dns/dns_resolver.rs:79:40
|
79 | ... last_err = io::Error::new(io::ErrorKind::Other, err);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
= note: `#[warn(clippy::io_other_error)]` on by default
help: use `std::io::Error::other`
|
79 - last_err = io::Error::new(io::ErrorKind::Other, err);
79 + last_err = io::Error::other(err);
|
Check warning on line 1358 in crates/shadowsocks-service/src/config.rs
github-actions / clippy macos-latest
this `if` can be collapsed into the outer `match`
warning: this `if` can be collapsed into the outer `match`
--> crates/shadowsocks-service/src/config.rs:1355:17
|
1355 | / if !self.mode.enable_tcp() {
1356 | | let err = Error::new(ErrorKind::Invalid, "TCP mode have to be enabled for http", None);
1357 | | return Err(err);
1358 | | }
| |_________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#collapsible_match
= note: `#[warn(clippy::collapsible_match)]` on by default
help: collapse nested if block
|
1354 ~ ProtocolType::Http
1355 ~ if !self.mode.enable_tcp() => {
1356 | let err = Error::new(ErrorKind::Invalid, "TCP mode have to be enabled for http", None);
1357 | return Err(err);
1358 ~ }
|
Check warning on line 195 in crates/shadowsocks/src/dns_resolver/hickory_dns_resolver.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks/src/dns_resolver/hickory_dns_resolver.rs:195:25
|
195 | Err(io::Error::new(io::ErrorKind::Other, err))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
195 - Err(io::Error::new(io::ErrorKind::Other, err))
195 + Err(io::Error::other(err))
|
Check warning on line 189 in crates/shadowsocks/src/dns_resolver/hickory_dns_resolver.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks/src/dns_resolver/hickory_dns_resolver.rs:189:33
|
189 | ... Err(io::Error::new(io::ErrorKind::Other, err))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
help: use `std::io::Error::other`
|
189 - Err(io::Error::new(io::ErrorKind::Other, err))
189 + Err(io::Error::other(err))
|
Check warning on line 164 in crates/shadowsocks/src/dns_resolver/hickory_dns_resolver.rs
github-actions / clippy macos-latest
this can be `std::io::Error::other(_)`
warning: this can be `std::io::Error::other(_)`
--> crates/shadowsocks/src/dns_resolver/hickory_dns_resolver.rs:164:25
|
164 | Err(io::Error::new(io::ErrorKind::Other, err))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#io_other_error
= note: `#[warn(clippy::io_other_error)]` on by default
help: use `std::io::Error::other`
|
164 - Err(io::Error::new(io::ErrorKind::Other, err))
164 + Err(io::Error::other(err))
|