mirror of
https://github.com/samba-team/samba.git
synced 2025-02-07 01:58:28 +03:00
r12238: don't crash when an error happens while connecting and the packet_context isn't inplace yet
metze (This used to be commit 064d9409c3dda25a803fd5ca9ad15c48271e8905)
This commit is contained in:
parent
daa4cce71d
commit
d09a32f5d7
@ -38,15 +38,18 @@ static void wrepl_socket_dead(struct wrepl_socket *wrepl_socket, NTSTATUS status
|
||||
talloc_set_destructor(wrepl_socket, NULL);
|
||||
wrepl_socket->dead = True;
|
||||
|
||||
if (wrepl_socket->event.fde) {
|
||||
if (wrepl_socket->packet) {
|
||||
packet_recv_disable(wrepl_socket->packet);
|
||||
packet_set_fde(wrepl_socket->packet, NULL);
|
||||
packet_set_socket(wrepl_socket->packet, NULL);
|
||||
}
|
||||
|
||||
if (wrepl_socket->event.fde) {
|
||||
talloc_free(wrepl_socket->event.fde);
|
||||
wrepl_socket->event.fde = NULL;
|
||||
}
|
||||
|
||||
if (wrepl_socket->sock) {
|
||||
packet_set_socket(wrepl_socket->packet, NULL);
|
||||
talloc_free(wrepl_socket->sock);
|
||||
wrepl_socket->sock = NULL;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user