[pbs-devel] [PATCH proxmox 04/13] http: make clippy happy

Fabian Grünbichler f.gruenbichler at proxmox.com
Fri May 14 15:44:40 CEST 2021


Signed-off-by: Fabian Grünbichler <f.gruenbichler at proxmox.com>
---
 proxmox-http/src/websocket/mod.rs | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/proxmox-http/src/websocket/mod.rs b/proxmox-http/src/websocket/mod.rs
index aac7304..b8f31dc 100644
--- a/proxmox-http/src/websocket/mod.rs
+++ b/proxmox-http/src/websocket/mod.rs
@@ -202,8 +202,7 @@ pub fn create_frame(
         0b00000000
     };
 
-    let mut buf = Vec::new();
-    buf.push(first_byte);
+    let mut buf = vec![first_byte];
 
     if len < 126 {
         buf.push(mask_bit | (len as u8));
-- 
2.20.1






More information about the pbs-devel mailing list