From: Ralph Boehme Date: Tue, 22 Oct 2024 05:56:53 +0000 (+0200) Subject: smbd: smbd_server_connection_terminate() may return X-Git-Tag: tdb-1.4.13~738 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ee5d3c63f60ec4d353d799f9427b5325de4cdccd;p=thirdparty%2Fsamba.git smbd: smbd_server_connection_terminate() may return BUG: https://bugzilla.samba.org/show_bug.cgi?id=15608 Signed-off-by: Ralph Boehme Reviewed-by: Stefan Metzmacher --- diff --git a/source3/smbd/smb2_negprot.c b/source3/smbd/smb2_negprot.c index f66ec2aa47f..b656865a2c8 100644 --- a/source3/smbd/smb2_negprot.c +++ b/source3/smbd/smb2_negprot.c @@ -911,10 +911,7 @@ static void smbd_smb2_request_process_negprot_mc_done(struct tevent_req *subreq) NT_STATUS_CONNECTION_IN_USE); smbd_server_connection_terminate(xconn, "passed connection"); - /* - * smbd_server_connection_terminate() should not return! - */ - smb_panic(__location__); + exit_server_cleanly("connection passed"); return; } if (!NT_STATUS_IS_OK(status)) { @@ -927,10 +924,7 @@ static void smbd_smb2_request_process_negprot_mc_done(struct tevent_req *subreq) * The connection was passed to another process */ smbd_server_connection_terminate(xconn, nt_errstr(status)); - /* - * smbd_server_connection_terminate() should not return! - */ - smb_panic(__location__); + exit_server_cleanly("connection passed"); return; } @@ -959,10 +953,7 @@ static void smbd_smb2_request_process_negprot_mc_done(struct tevent_req *subreq) * The connection was passed to another process */ smbd_server_connection_terminate(xconn, nt_errstr(status)); - /* - * smbd_server_connection_terminate() should not return! - */ - smb_panic(__location__); + exit_server_cleanly("connection passed"); return; }