summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2006-03-15 02:41:57 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:57:20 -0500
commitf479571502750c2399103bbdd104966125ce3818 (patch)
tree0097a09837a737f2d11ab8297568116308eadb3a /source4
parent0f921145d5bb687f2cbf4217fc199d3a133ac583 (diff)
downloadsamba-f479571502750c2399103bbdd104966125ce3818.tar.gz
samba-f479571502750c2399103bbdd104966125ce3818.tar.bz2
samba-f479571502750c2399103bbdd104966125ce3818.zip
r14413: don't do memcpy of length 0
(This used to be commit c43a7ec7ac3bcb3001d046615ca17a9ce083a2b0)
Diffstat (limited to 'source4')
-rw-r--r--source4/libcli/raw/rawtrans.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source4/libcli/raw/rawtrans.c b/source4/libcli/raw/rawtrans.c
index 207b5bee08..53e80d4753 100644
--- a/source4/libcli/raw/rawtrans.c
+++ b/source4/libcli/raw/rawtrans.c
@@ -340,7 +340,10 @@ struct smbcli_request *smb_raw_trans_send_backend(struct smbcli_tree *tree,
SSVAL(req2->out.vwv,VWV(7), data_disp);
SSVAL(req2->out.vwv,VWV(8), 0xFFFF);
- memcpy(req2->out.data, parms->in.data.data + data_disp, data_length);
+ if (data_length != 0) {
+ memcpy(req2->out.data, parms->in.data.data + data_disp,
+ data_length);
+ }
data_disp += data_length;