diff options
author | Stefan Metzmacher <metze@samba.org> | 2011-10-27 22:55:17 +0200 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2011-10-28 09:55:48 +0200 |
commit | 6c07505b15e3822cf5fe09b0e32794b6abecbeeb (patch) | |
tree | 6fa3151145a16d10416db4e98cd505a3106f32e1 | |
parent | 926b3394b653a9bef561fea9c89a18a1850df6f9 (diff) | |
download | samba-6c07505b15e3822cf5fe09b0e32794b6abecbeeb.tar.gz samba-6c07505b15e3822cf5fe09b0e32794b6abecbeeb.tar.bz2 samba-6c07505b15e3822cf5fe09b0e32794b6abecbeeb.zip |
s4:librpc/dcerpc_smb2: fix smb2_write_callback()
The should use smb2_write_recv() to get the result.
metze
Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Fri Oct 28 09:55:48 CEST 2011 on sn-devel-104
-rw-r--r-- | source4/librpc/rpc/dcerpc_smb2.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/source4/librpc/rpc/dcerpc_smb2.c b/source4/librpc/rpc/dcerpc_smb2.c index 75fb423df4..0de8935797 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); + } } /* |