diff options
author | Stefan Metzmacher <metze@samba.org> | 2006-07-13 15:46:36 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 14:10:08 -0500 |
commit | 39b7ae11ace37241e4d9b710a85b3428ac234219 (patch) | |
tree | 083f7f896de0b59d55f82e94bc37b7d019ba0be9 /source4/smb_server/smb | |
parent | 669e5d0fab89cc6c64010d321223c3948cd676f8 (diff) | |
download | samba-39b7ae11ace37241e4d9b710a85b3428ac234219.tar.gz samba-39b7ae11ace37241e4d9b710a85b3428ac234219.tar.bz2 samba-39b7ae11ace37241e4d9b710a85b3428ac234219.zip |
r17012: don't try to send any data when the socket is gone already...
(fixes crash bugs)
metze
(This used to be commit b7418aec33033577de2420c70a8b94a2fb7901dd)
Diffstat (limited to 'source4/smb_server/smb')
-rw-r--r-- | source4/smb_server/smb/request.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source4/smb_server/smb/request.c b/source4/smb_server/smb/request.c index fc7d060ea8..00bed16fc4 100644 --- a/source4/smb_server/smb/request.c +++ b/source4/smb_server/smb/request.c @@ -289,6 +289,7 @@ void smbsrv_send_reply_nosign(struct smbsrv_request *req) if (req->smb_conn->connection->event.fde == NULL) { /* we are in the process of shutting down this connection */ + talloc_free(req); return; } @@ -312,6 +313,11 @@ void smbsrv_send_reply_nosign(struct smbsrv_request *req) */ void smbsrv_send_reply(struct smbsrv_request *req) { + if (req->smb_conn->connection->event.fde == NULL) { + /* we are in the process of shutting down this connection */ + talloc_free(req); + return; + } smbsrv_sign_packet(req); smbsrv_send_reply_nosign(req); |