From dec0ed1a4dfbeaecd2954fe0d878bfa1aa311a01 Mon Sep 17 00:00:00 2001 From: Andrew Whitehead Date: Tue, 4 Jan 2022 15:37:16 -0800 Subject: [PATCH] drop worker shared state in shutdown (#1608) Signed-off-by: Andrew Whitehead --- sqlx-core/src/sqlite/connection/worker.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sqlx-core/src/sqlite/connection/worker.rs b/sqlx-core/src/sqlite/connection/worker.rs index 527e363a..b737fbf3 100644 --- a/sqlx-core/src/sqlite/connection/worker.rs +++ b/sqlx-core/src/sqlite/connection/worker.rs @@ -215,9 +215,10 @@ impl ConnectionWorker { tx.send(()).ok(); } Command::Shutdown { tx } => { - // drop the connection reference before sending confirmation + // drop the connection references before sending confirmation // and ending the command loop drop(conn); + drop(shared); let _ = tx.send(()); return; }