Skip to content

Commit ed0e560

Browse files
committed
async/server: Fix the the dropping of the server object
Break the accepting-new-connection loop correctly when the server object was dropped. Fixes: #284 Signed-off-by: Tim Zhang <tim@hyper.sh>
1 parent d79bd82 commit ed0e560

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/asynchronous/server.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@ impl Server {
162162
fd_tx = stop_listen_rx.recv() => {
163163
if let Some(fd_tx) = fd_tx {
164164
fd_tx.send(incoming).await.unwrap();
165-
break;
166165
}
166+
break;
167167
}
168168
}
169169
}

0 commit comments

Comments
 (0)