Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 88d5702d authored by Chris Wailes's avatar Chris Wailes
Browse files

Fix warnings in preperatin for Rust 1.53.0

This CL fixes several new warnings generated by rustc 1.53.0.

Bug: 194400612
Test: m rust
Change-Id: Ibe6471f286fb0417a429dafa8771dcdb1c43fe45
parent 53d3eb2a
Loading
Loading
Loading
Loading
+15 −19
Original line number Diff line number Diff line
@@ -382,8 +382,7 @@ impl DohConnection {
            .timeout()
            .unwrap_or_else(|| Duration::from_millis(QUICHE_IDLE_TIMEOUT_MS));
        match timeout(ts, self.udp_sk.recv_from(&mut buf)).await {
            Ok(v) => {
                match v {
            Ok(v) => match v {
                Ok((size, from)) => {
                    let recv_info = quiche::RecvInfo { from };
                    let processed = match self.quic_conn.recv(&mut buf[..size], recv_info) {
@@ -393,17 +392,14 @@ impl DohConnection {
                        }
                    };
                    debug!("processed {} bytes", processed);
                        return Ok(());
                    }
                    Err(e) => {
                        return Err(anyhow!("socket recv failed: {:?}", e));
                    }
                };
                    Ok(())
                }
                Err(e) => Err(anyhow!("socket recv failed: {:?}", e)),
            },
            Err(_) => {
                warn!("timeout did not receive value within {:?} ms, {}", ts, self.net_id);
                self.quic_conn.on_timeout();
                return Ok(());
                Ok(())
            }
        }
    }