From 9e09c89bb799a340ea11f37f7ca3bbc4d2c02d5d Mon Sep 17 00:00:00 2001 From: zxj Date: Wed, 18 May 2022 16:19:21 +0800 Subject: [PATCH] edit recv_all --- src/fast_log.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/fast_log.rs b/src/fast_log.rs index dd919d6..ed97942 100644 --- a/src/fast_log.rs +++ b/src/fast_log.rs @@ -160,7 +160,7 @@ pub fn init(config: Config) -> Result<&'static Logger, LogError> { if let Ok(mut data) = data { let mut remain; if LOG_SENDER.recv.len() > 0 { - remain = Vec::with_capacity(LOG_SENDER.recv.len()); + remain = Vec::with_capacity(LOG_SENDER.recv.len()+1); remain.push(data); recv_all(&mut remain,&LOG_SENDER.recv); } else {