diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2007-09-08 16:46:30 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 15:05:43 -0500 |
commit | 98b57d5eb61094a9c88e2f7d90d3e21b7e74e9d8 (patch) | |
tree | 044b24a249cc2b63c2f69214d7e7da288c170c74 /source4/smb_server | |
parent | ce0ff008b5c5af931526d14fa6232f8647e0880f (diff) | |
download | samba-98b57d5eb61094a9c88e2f7d90d3e21b7e74e9d8.tar.gz samba-98b57d5eb61094a9c88e2f7d90d3e21b7e74e9d8.tar.bz2 samba-98b57d5eb61094a9c88e2f7d90d3e21b7e74e9d8.zip |
r25035: Fix some more warnings, use service pointer rather than service number in more places.
(This used to be commit df9cebcb97e20564359097148665bd519f31bc6f)
Diffstat (limited to 'source4/smb_server')
-rw-r--r-- | source4/smb_server/smb2/negprot.c | 2 | ||||
-rw-r--r-- | source4/smb_server/smb2/receive.c | 3 | ||||
-rw-r--r-- | source4/smb_server/smb2/tcon.c | 3 |
3 files changed, 5 insertions, 3 deletions
diff --git a/source4/smb_server/smb2/negprot.c b/source4/smb_server/smb2/negprot.c index 2aca91adf8..8aa652e27e 100644 --- a/source4/smb_server/smb2/negprot.c +++ b/source4/smb_server/smb2/negprot.c @@ -196,7 +196,7 @@ void smb2srv_reply_smb_negprot(struct smbsrv_request *smb_req) req->in.size = NBT_HDR_SIZE+SMB2_HDR_BODY+body_fixed_size; req->in.allocated = req->in.size; - req->in.buffer = talloc_size(req, req->in.allocated); + req->in.buffer = talloc_array(req, uint8_t, req->in.allocated); if (!req->in.buffer) goto nomem; req->in.hdr = req->in.buffer + NBT_HDR_SIZE; req->in.body = req->in.hdr + SMB2_HDR_BODY; diff --git a/source4/smb_server/smb2/receive.c b/source4/smb_server/smb2/receive.c index 6a36d2f365..e783620e52 100644 --- a/source4/smb_server/smb2/receive.c +++ b/source4/smb_server/smb2/receive.c @@ -82,7 +82,8 @@ NTSTATUS smb2srv_setup_reply(struct smb2srv_request *req, uint16_t body_fixed_si req->out.size = SMB2_HDR_BODY+NBT_HDR_SIZE+body_fixed_size; req->out.allocated = req->out.size + body_dynamic_size; - req->out.buffer = talloc_size(req, req->out.allocated); + req->out.buffer = talloc_array(req, uint8_t, + req->out.allocated); NT_STATUS_HAVE_NO_MEMORY(req->out.buffer); req->out.hdr = req->out.buffer + NBT_HDR_SIZE; diff --git a/source4/smb_server/smb2/tcon.c b/source4/smb_server/smb2/tcon.c index b476e97168..6d7e19e470 100644 --- a/source4/smb_server/smb2/tcon.c +++ b/source4/smb_server/smb2/tcon.c @@ -41,7 +41,8 @@ static NTSTATUS smb2srv_send_oplock_break(void *p, struct ntvfs_handle *h, uint8 req = smb2srv_init_request(handle->tcon->smb_conn); NT_STATUS_HAVE_NO_MEMORY(req); - req->in.buffer = talloc_size(req, NBT_HDR_SIZE + SMB2_MIN_SIZE); + req->in.buffer = talloc_array(req, uint8_t, + NBT_HDR_SIZE + SMB2_MIN_SIZE); NT_STATUS_HAVE_NO_MEMORY(req->in.buffer); req->in.size = NBT_HDR_SIZE + SMB2_MIN_SIZE; req->in.allocated = req->in.size; |