summaryrefslogtreecommitdiff
path: root/source4/librpc/rpc/dcerpc_smb.c
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2007-04-22 23:00:22 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:51:29 -0500
commit1912124dbfc501c5109f6ac36e125406078d408c (patch)
treea863846bd767627125f22abd26be74db66d81664 /source4/librpc/rpc/dcerpc_smb.c
parentcc5ad07d84df94f8f2bc16fcb8015f1cf843c1e3 (diff)
downloadsamba-1912124dbfc501c5109f6ac36e125406078d408c.tar.gz
samba-1912124dbfc501c5109f6ac36e125406078d408c.tar.bz2
samba-1912124dbfc501c5109f6ac36e125406078d408c.zip
r22470: merge handling of broken connections from wins replication client code
to the rpc client code we need to always ask for read events on the socket otherwise we never get the connection error reported. shutdown the transport when a request timeout. metze (This used to be commit 3403c0cb15e08ec838b0bc834f941051fb94d124)
Diffstat (limited to 'source4/librpc/rpc/dcerpc_smb.c')
-rw-r--r--source4/librpc/rpc/dcerpc_smb.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source4/librpc/rpc/dcerpc_smb.c b/source4/librpc/rpc/dcerpc_smb.c
index d6d2cf0dfb..55fc37d84f 100644
--- a/source4/librpc/rpc/dcerpc_smb.c
+++ b/source4/librpc/rpc/dcerpc_smb.c
@@ -326,14 +326,14 @@ static NTSTATUS smb_send_request(struct dcerpc_connection *c, DATA_BLOB *blob, B
/*
shutdown SMB pipe connection
*/
-static NTSTATUS smb_shutdown_pipe(struct dcerpc_connection *c)
+static NTSTATUS smb_shutdown_pipe(struct dcerpc_connection *c, NTSTATUS status)
{
struct smb_private *smb = c->transport.private;
union smb_close io;
struct smbcli_request *req;
/* maybe we're still starting up */
- if (!smb) return NT_STATUS_OK;
+ if (!smb) return status;
io.close.level = RAW_CLOSE_CLOSE;
io.close.in.file.fnum = smb->fnum;
@@ -346,7 +346,7 @@ static NTSTATUS smb_shutdown_pipe(struct dcerpc_connection *c)
talloc_free(smb);
- return NT_STATUS_OK;
+ return status;
}
/*