[SCM] Samba Shared Repository - branch master updated
Stefan Metzmacher
metze at samba.org
Fri Oct 28 01:56:03 MDT 2011
The branch, master has been updated
via 6c07505 s4:librpc/dcerpc_smb2: fix smb2_write_callback()
via 926b339 s4:librpc/dcerpc_smb: fix smb_write_callback()
from ac79427 s4:torture:smb2: avoid leaking tree connects up to the main function from the durable_open test
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit 6c07505b15e3822cf5fe09b0e32794b6abecbeeb
Author: Stefan Metzmacher <metze at samba.org>
Date: Thu Oct 27 22:55:17 2011 +0200
s4:librpc/dcerpc_smb2: fix smb2_write_callback()
The should use smb2_write_recv() to get the result.
metze
Autobuild-User: Stefan Metzmacher <metze at samba.org>
Autobuild-Date: Fri Oct 28 09:55:48 CEST 2011 on sn-devel-104
commit 926b3394b653a9bef561fea9c89a18a1850df6f9
Author: Stefan Metzmacher <metze at samba.org>
Date: Thu Oct 27 22:55:17 2011 +0200
s4:librpc/dcerpc_smb: fix smb_write_callback()
The should use smb_raw_write_recv() to get the result.
metze
-----------------------------------------------------------------------
Summary of changes:
source4/librpc/rpc/dcerpc_smb.c | 15 ++++++++++-----
source4/librpc/rpc/dcerpc_smb2.c | 14 +++++++++-----
2 files changed, 19 insertions(+), 10 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source4/librpc/rpc/dcerpc_smb.c b/source4/librpc/rpc/dcerpc_smb.c
index c231295..bdba217 100644
--- a/source4/librpc/rpc/dcerpc_smb.c
+++ b/source4/librpc/rpc/dcerpc_smb.c
@@ -308,13 +308,18 @@ static NTSTATUS smb_send_trans_request(struct dcecli_connection *c, DATA_BLOB *b
static void smb_write_callback(struct smbcli_request *req)
{
struct dcecli_connection *c = (struct dcecli_connection *)req->async.private_data;
+ union smb_write io;
+ NTSTATUS status;
- if (!NT_STATUS_IS_OK(req->status)) {
- DEBUG(0,("dcerpc_smb: write callback error\n"));
- pipe_dead(c, req->status);
- }
+ ZERO_STRUCT(io);
+ io.generic.level = RAW_WRITE_WRITEX;
- smbcli_request_destroy(req);
+ status = smb_raw_write_recv(req, &io);
+ if (!NT_STATUS_IS_OK(status)) {
+ DEBUG(0,("dcerpc_smb: write callback error: %s\n",
+ nt_errstr(status)));
+ pipe_dead(c, status);
+ }
}
/*
diff --git a/source4/librpc/rpc/dcerpc_smb2.c b/source4/librpc/rpc/dcerpc_smb2.c
index 75fb423..0de8935 100644
--- a/source4/librpc/rpc/dcerpc_smb2.c
+++ b/source4/librpc/rpc/dcerpc_smb2.c
@@ -284,13 +284,17 @@ static NTSTATUS smb2_send_trans_request(struct dcecli_connection *c, DATA_BLOB *
static void smb2_write_callback(struct smb2_request *req)
{
struct dcecli_connection *c = (struct dcecli_connection *)req->async.private_data;
+ struct smb2_write io;
+ NTSTATUS status;
- if (!NT_STATUS_IS_OK(req->status)) {
- DEBUG(0,("dcerpc_smb2: write callback error\n"));
- pipe_dead(c, req->status);
- }
+ ZERO_STRUCT(io);
- smb2_request_destroy(req);
+ status = smb2_write_recv(req, &io);
+ if (!NT_STATUS_IS_OK(status)) {
+ DEBUG(0,("dcerpc_smb2: write callback error: %s\n",
+ nt_errstr(status)));
+ pipe_dead(c, status);
+ }
}
/*
--
Samba Shared Repository
More information about the samba-cvs
mailing list