1
0
mirror of https://github.com/samba-team/samba.git synced 2025-08-02 00:22:11 +03:00

r4591: - converted the other _p talloc functions to not need _p

- added #if TALLOC_DEPRECATED around the _p functions

- fixes the code that broke from the above

while doing this I fixed quite a number of places that were
incorrectly using the non type-safe talloc functions to use the type
safe ones. Some were even doing multiplies for array allocation, which
is potentially unsafe.
(This used to be commit 6e7754abd0)
This commit is contained in:
Andrew Tridgell
2005-01-07 04:39:16 +00:00
committed by Gerald (Jerry) Carter
parent 066134f241
commit 11ce2cfd70
39 changed files with 136 additions and 105 deletions

View File

@ -111,7 +111,7 @@ NTSTATUS smb_raw_trans2_recv(struct smbcli_request *req,
if (parms->out.setup_count > 0) {
int i;
parms->out.setup = talloc_array(mem_ctx, 2, parms->out.setup_count, "setup");
parms->out.setup = talloc_array(mem_ctx, uint16_t, parms->out.setup_count);
if (!parms->out.setup) {
req->status = NT_STATUS_NO_MEMORY;
return smbcli_request_destroy(req);
@ -439,7 +439,7 @@ NTSTATUS smb_raw_nttrans_recv(struct smbcli_request *req,
if (parms->out.setup_count > 0) {
int i;
parms->out.setup = talloc_array(mem_ctx, 2, parms->out.setup_count, "setup");
parms->out.setup = talloc_array(mem_ctx, uint16_t, parms->out.setup_count);
if (!parms->out.setup) {
req->status = NT_STATUS_NO_MEMORY;
return smbcli_request_destroy(req);