smbXsrv_client: call smb2srv_client_connection_{pass,drop}() before dbwrap_watched_wa...
commit56c597bc2b29dc3e555f737ba189f521d0e31e8c
authorStefan Metzmacher <metze@samba.org>
Wed, 12 Oct 2022 11:54:41 +0000 (12 13:54 +0200)
committerRalph Boehme <slow@samba.org>
Thu, 13 Oct 2022 12:30:37 +0000 (13 12:30 +0000)
tree0768e97e97831671490ca36c5669830432627162
parentacb3d821deaf06faa16f6428682ecdb02babeb98
smbXsrv_client: call smb2srv_client_connection_{pass,drop}() before dbwrap_watched_watch_send()

dbwrap_watched_watch_send() should typically be the last thing to call
before the db record is unlocked, as it's not that easy to undo.

In future we want to recover from smb2srv_client_connection_{pass,drop}()
returning NT_STATUS_OBJECT_NAME_NOT_FOUND and it would add complexity if
would need to undo dbwrap_watched_watch_send() at that point.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15200

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
source3/smbd/smbXsrv_client.c