about summary refs log tree commit diff
path: root/library/std/src/sys/solid/net.rs
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2023-09-03 09:28:31 +0200
committerRalf Jung <post@ralfj.de>2023-09-03 09:28:31 +0200
commitfb26c21c356075c0cd35d98fa0b786b7633249d8 (patch)
tree62acd3e15506a4b53b29a70b7882c0c2fa0352b4 /library/std/src/sys/solid/net.rs
parentdc81d6c2827bb23e75f1dc6c42e9c705ed976ba1 (diff)
parenta989e25f1b87949a886eab3da10324d14189fe95 (diff)
downloadrust-fb26c21c356075c0cd35d98fa0b786b7633249d8.tar.gz
rust-fb26c21c356075c0cd35d98fa0b786b7633249d8.zip
Merge from rustc
Diffstat (limited to 'library/std/src/sys/solid/net.rs')
-rw-r--r--library/std/src/sys/solid/net.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/library/std/src/sys/solid/net.rs b/library/std/src/sys/solid/net.rs
index bdd64ab02b7..6adced787f3 100644
--- a/library/std/src/sys/solid/net.rs
+++ b/library/std/src/sys/solid/net.rs
@@ -183,8 +183,7 @@ pub(super) fn error_name(er: abi::ER) -> Option<&'static str> {
 
 #[inline]
 pub fn is_interrupted(er: abi::ER) -> bool {
-    let errno = netc::SOLID_NET_ERR_BASE - er;
-    errno as libc::c_int == libc::EINTR
+    er == netc::SOLID_NET_ERR_BASE - libc::EINTR
 }
 
 pub(super) fn decode_error_kind(er: abi::ER) -> ErrorKind {