File tree Expand file tree Collapse file tree
mitmproxy-contentviews/src/protobuf
wireguard-test-client/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -81,7 +81,7 @@ impl GRPC {
8181 & decompressed
8282 }
8383 "identity" => proto,
84- _ => bail ! ( "unsupported compression: {}" , encoding ) ,
84+ _ => bail ! ( "unsupported compression: {encoding}" ) ,
8585 }
8686 } else {
8787 proto
Original file line number Diff line number Diff line change @@ -143,7 +143,7 @@ pub fn start_local_redirector(
143143 if let Some ( copy_task) = copy_task {
144144 tokio:: task:: spawn_blocking ( copy_task)
145145 . await
146- . map_err ( |e| anyhow:: anyhow!( "failed to copy: {}" , e ) ) ??;
146+ . map_err ( |e| anyhow:: anyhow!( "failed to copy: {e}" ) ) ??;
147147 }
148148 let ( server, conf_tx) =
149149 Server :: init ( conf, handle_tcp_stream, handle_udp_stream) . await ?;
Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ impl TryFrom<&str> for InterceptConf {
4949 return Ok ( InterceptConf :: new ( vec ! [ ] ) ) ;
5050 }
5151 let actions: Vec < & str > = val. split ( ',' ) . collect ( ) ;
52- InterceptConf :: try_from ( actions) . map_err ( |_| anyhow ! ( "invalid intercept spec: {}" , value ) )
52+ InterceptConf :: try_from ( actions) . map_err ( |_| anyhow ! ( "invalid intercept spec: {value}" ) )
5353 }
5454}
5555
Original file line number Diff line number Diff line change @@ -176,7 +176,7 @@ impl TryFrom<Vec<u8>> for SmolPacket {
176176 match value[ 0 ] >> 4 {
177177 4 => Ok ( SmolPacket :: V4 ( Ipv4Packet :: new_checked ( value) ?) ) ,
178178 6 => Ok ( SmolPacket :: V6 ( Ipv6Packet :: new_checked ( value) ?) ) ,
179- _ => Err ( anyhow ! ( "Not an IP packet: {:?}" , value ) ) ,
179+ _ => Err ( anyhow ! ( "Not an IP packet: {value :?}" ) ) ,
180180 }
181181 }
182182}
Original file line number Diff line number Diff line change @@ -805,7 +805,7 @@ async fn receive_icmp4_echo() -> Result<()> {
805805 let mut input_icmpv4_packet = match Icmpv4Packet :: new_checked ( response. payload_mut ( ) ) {
806806 Ok ( p) => p,
807807 Err ( e) => {
808- return Err ( anyhow ! ( "Invalid ICMPv4 packet emitted: {}" , e ) ) ;
808+ return Err ( anyhow ! ( "Invalid ICMPv4 packet emitted: {e}" ) ) ;
809809 }
810810 } ;
811811
@@ -843,7 +843,7 @@ async fn receive_icmp6_echo() -> Result<()> {
843843 let mut input_icmpv6_packet = match Icmpv6Packet :: new_checked ( response. payload_mut ( ) ) {
844844 Ok ( p) => p,
845845 Err ( e) => {
846- return Err ( anyhow ! ( "Invalid ICMPv6 packet emitted: {}" , e ) ) ;
846+ return Err ( anyhow ! ( "Invalid ICMPv6 packet emitted: {e}" ) ) ;
847847 }
848848 } ;
849849
Original file line number Diff line number Diff line change @@ -209,7 +209,7 @@ impl ConnectionTask {
209209 . handle_udp ( udp_flow)
210210 . await
211211 . context ( "failed to handle UDP stream" ) ,
212- _ => bail ! ( "Received invalid IPC message: {:?}" , new_flow ) ,
212+ _ => bail ! ( "Received invalid IPC message: {new_flow :?}" ) ,
213213 }
214214 }
215215
Original file line number Diff line number Diff line change @@ -138,7 +138,7 @@ cafe0050123456790000000050100204FFFF0000\
138138 }
139139 }
140140 TunnResult :: Done => ( ) ,
141- _ => bail ! ( "Unexpected decapsulatation result: {:?}" , result ) ,
141+ _ => bail ! ( "Unexpected decapsulatation result: {result :?}" ) ,
142142 }
143143 }
144144 println ! ( "All set!" ) ;
You can’t perform that action at this time.
0 commit comments