drop worker shared state in shutdown (#1608)

Signed-off-by: Andrew Whitehead <cywolf@gmail.com>
This commit is contained in:
Andrew Whitehead 2022-01-04 15:37:16 -08:00 committed by GitHub
parent bcb2d8e604
commit dec0ed1a4d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -215,9 +215,10 @@ impl ConnectionWorker {
tx.send(()).ok(); tx.send(()).ok();
} }
Command::Shutdown { tx } => { Command::Shutdown { tx } => {
// drop the connection reference before sending confirmation // drop the connection references before sending confirmation
// and ending the command loop // and ending the command loop
drop(conn); drop(conn);
drop(shared);
let _ = tx.send(()); let _ = tx.send(());
return; return;
} }