summaryrefslogtreecommitdiff
path: root/source4/librpc
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2005-01-27 07:08:20 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:09:15 -0500
commit759da3b915e2006d4c87b5ace47f399accd9ce91 (patch)
tree6bcaf9d4c0e38ef5e975c041d442c4437aa61e5a /source4/librpc
parent1e42cacf6a8643bd633f631c212d71760852abbc (diff)
downloadsamba-759da3b915e2006d4c87b5ace47f399accd9ce91.tar.gz
samba-759da3b915e2006d4c87b5ace47f399accd9ce91.tar.bz2
samba-759da3b915e2006d4c87b5ace47f399accd9ce91.zip
r5037: got rid of all of the TALLOC_DEPRECATED stuff. My apologies for the
large commit. I thought this was worthwhile to get done for consistency. (This used to be commit ec32b22ed5ec224f6324f5e069d15e92e38e15c0)
Diffstat (limited to 'source4/librpc')
-rw-r--r--source4/librpc/ndr/ndr.c14
-rw-r--r--source4/librpc/ndr/ndr_dcom.c18
-rw-r--r--source4/librpc/rpc/dcerpc.c8
-rw-r--r--source4/librpc/rpc/dcerpc_schannel.c6
-rw-r--r--source4/librpc/rpc/dcerpc_smb.c10
-rw-r--r--source4/librpc/rpc/dcerpc_sock.c4
-rw-r--r--source4/librpc/rpc/dcerpc_util.c4
7 files changed, 32 insertions, 32 deletions
diff --git a/source4/librpc/ndr/ndr.c b/source4/librpc/ndr/ndr.c
index 8a25e27cc1..6947cc8ee6 100644
--- a/source4/librpc/ndr/ndr.c
+++ b/source4/librpc/ndr/ndr.c
@@ -48,7 +48,7 @@ struct ndr_pull *ndr_pull_init_blob(const DATA_BLOB *blob, TALLOC_CTX *mem_ctx)
{
struct ndr_pull *ndr;
- ndr = talloc_zero_p(mem_ctx, struct ndr_pull);
+ ndr = talloc_zero(mem_ctx, struct ndr_pull);
if (!ndr) return NULL;
ndr->data = blob->data;
@@ -121,14 +121,14 @@ struct ndr_push *ndr_push_init_ctx(TALLOC_CTX *mem_ctx)
{
struct ndr_push *ndr;
- ndr = talloc_zero_p(mem_ctx, struct ndr_push);
+ ndr = talloc_zero(mem_ctx, struct ndr_push);
if (!ndr) {
return NULL;
}
ndr->flags = 0;
ndr->alloc_size = NDR_BASE_MARSHALL_SIZE;
- ndr->data = talloc_array_p(ndr, uint8_t, ndr->alloc_size);
+ ndr->data = talloc_array(ndr, uint8_t, ndr->alloc_size);
if (!ndr->data) {
return NULL;
}
@@ -315,7 +315,7 @@ void ndr_print_debug(ndr_print_fn_t fn, const char *name, void *ptr)
{
struct ndr_print *ndr;
- ndr = talloc_p(NULL, struct ndr_print);
+ ndr = talloc(NULL, struct ndr_print);
if (!ndr) return;
ndr->print = ndr_print_debug_helper;
ndr->depth = 1;
@@ -332,7 +332,7 @@ void ndr_print_union_debug(ndr_print_union_fn_t fn, const char *name, uint32_t l
{
struct ndr_print *ndr;
- ndr = talloc_p(NULL, struct ndr_print);
+ ndr = talloc(NULL, struct ndr_print);
if (!ndr) return;
ndr->print = ndr_print_debug_helper;
ndr->depth = 1;
@@ -348,7 +348,7 @@ void ndr_print_function_debug(ndr_print_function_t fn, const char *name, int fla
{
struct ndr_print *ndr;
- ndr = talloc_p(NULL, struct ndr_print);
+ ndr = talloc(NULL, struct ndr_print);
if (!ndr) return;
ndr->print = ndr_print_debug_helper;
ndr->depth = 1;
@@ -639,7 +639,7 @@ static NTSTATUS ndr_token_store(TALLOC_CTX *mem_ctx,
uint32_t value)
{
struct ndr_token_list *tok;
- tok = talloc_p(mem_ctx, struct ndr_token_list);
+ tok = talloc(mem_ctx, struct ndr_token_list);
if (tok == NULL) {
return NT_STATUS_NO_MEMORY;
}
diff --git a/source4/librpc/ndr/ndr_dcom.c b/source4/librpc/ndr/ndr_dcom.c
index ee077dfd4f..71a43a8fff 100644
--- a/source4/librpc/ndr/ndr_dcom.c
+++ b/source4/librpc/ndr/ndr_dcom.c
@@ -37,7 +37,7 @@ NTSTATUS ndr_pull_DUALSTRINGARRAY(struct ndr_pull *ndr, int ndr_flags, struct DU
NDR_CHECK(ndr_pull_uint16(ndr, &num_entries));
NDR_CHECK(ndr_pull_uint16(ndr, &security_offset));
- ar->stringbindings = talloc_array_p(ndr, struct STRINGBINDING *, num_entries);
+ ar->stringbindings = talloc_array(ndr, struct STRINGBINDING *, num_entries);
ar->stringbindings[0] = NULL;
do {
@@ -46,8 +46,8 @@ NTSTATUS ndr_pull_DUALSTRINGARRAY(struct ndr_pull *ndr, int ndr_flags, struct DU
if (towerid > 0) {
ndr->offset -= 2;
- ar->stringbindings = talloc_realloc_p(ndr, ar->stringbindings, struct STRINGBINDING *, towernum+2);
- ar->stringbindings[towernum] = talloc_p(ndr, struct STRINGBINDING);
+ ar->stringbindings = talloc_realloc(ndr, ar->stringbindings, struct STRINGBINDING *, towernum+2);
+ ar->stringbindings[towernum] = talloc(ndr, struct STRINGBINDING);
NDR_CHECK(ndr_pull_STRINGBINDING(ndr, ndr_flags, ar->stringbindings[towernum]));
towernum++;
}
@@ -56,7 +56,7 @@ NTSTATUS ndr_pull_DUALSTRINGARRAY(struct ndr_pull *ndr, int ndr_flags, struct DU
ar->stringbindings[towernum] = NULL;
towernum = 0;
- ar->securitybindings = talloc_array_p(ndr, struct SECURITYBINDING *, num_entries);
+ ar->securitybindings = talloc_array(ndr, struct SECURITYBINDING *, num_entries);
ar->securitybindings[0] = NULL;
do {
@@ -65,8 +65,8 @@ NTSTATUS ndr_pull_DUALSTRINGARRAY(struct ndr_pull *ndr, int ndr_flags, struct DU
if (towerid > 0) {
ndr->offset -= 2;
- ar->securitybindings = talloc_realloc_p(ndr, ar->securitybindings, struct SECURITYBINDING *, towernum+2);
- ar->securitybindings[towernum] = talloc_p(ndr, struct SECURITYBINDING);
+ ar->securitybindings = talloc_realloc(ndr, ar->securitybindings, struct SECURITYBINDING *, towernum+2);
+ ar->securitybindings[towernum] = talloc(ndr, struct SECURITYBINDING);
NDR_CHECK(ndr_pull_SECURITYBINDING(ndr, ndr_flags, ar->securitybindings[towernum]));
towernum++;
}
@@ -126,7 +126,7 @@ NTSTATUS ndr_pull_STRINGARRAY(struct ndr_pull *ndr, int ndr_flags, struct STRING
NDR_CHECK(ndr_pull_uint16(ndr, &num_entries));
- ar->stringbindings = talloc_array_p(ndr, struct STRINGBINDING *, 1);
+ ar->stringbindings = talloc_array(ndr, struct STRINGBINDING *, 1);
ar->stringbindings[0] = NULL;
do {
@@ -135,8 +135,8 @@ NTSTATUS ndr_pull_STRINGARRAY(struct ndr_pull *ndr, int ndr_flags, struct STRING
if (towerid > 0) {
ndr->offset -= 2;
- ar->stringbindings = talloc_realloc_p(ndr, ar->stringbindings, struct STRINGBINDING *, towernum+2);
- ar->stringbindings[towernum] = talloc_p(ndr, struct STRINGBINDING);
+ ar->stringbindings = talloc_realloc(ndr, ar->stringbindings, struct STRINGBINDING *, towernum+2);
+ ar->stringbindings[towernum] = talloc(ndr, struct STRINGBINDING);
NDR_CHECK(ndr_pull_STRINGBINDING(ndr, ndr_flags, ar->stringbindings[towernum]));
towernum++;
}
diff --git a/source4/librpc/rpc/dcerpc.c b/source4/librpc/rpc/dcerpc.c
index e133c77d07..bdf9cb2581 100644
--- a/source4/librpc/rpc/dcerpc.c
+++ b/source4/librpc/rpc/dcerpc.c
@@ -33,7 +33,7 @@ static struct dcerpc_interface_list *dcerpc_pipes = NULL;
*/
NTSTATUS librpc_register_interface(const struct dcerpc_interface_table *interface)
{
- struct dcerpc_interface_list *l = talloc_p(talloc_autofree_context(),
+ struct dcerpc_interface_list *l = talloc(talloc_autofree_context(),
struct dcerpc_interface_list);
if (idl_iface_by_name (interface->name) != NULL) {
@@ -96,7 +96,7 @@ struct dcerpc_pipe *dcerpc_pipe_init(TALLOC_CTX *mem_ctx)
{
struct dcerpc_pipe *p;
- p = talloc_p(mem_ctx, struct dcerpc_pipe);
+ p = talloc(mem_ctx, struct dcerpc_pipe);
if (!p) {
return NULL;
}
@@ -534,7 +534,7 @@ static NTSTATUS full_request(struct dcerpc_connection *c,
DATA_BLOB *request_blob,
DATA_BLOB *reply_blob)
{
- struct full_request_state *state = talloc_p(mem_ctx, struct full_request_state);
+ struct full_request_state *state = talloc(mem_ctx, struct full_request_state);
NTSTATUS status;
if (state == NULL) {
@@ -864,7 +864,7 @@ struct rpc_request *dcerpc_request_send(struct dcerpc_pipe *p,
p->conn->transport.recv_data = dcerpc_request_recv_data;
- req = talloc_p(mem_ctx, struct rpc_request);
+ req = talloc(mem_ctx, struct rpc_request);
if (req == NULL) {
return NULL;
}
diff --git a/source4/librpc/rpc/dcerpc_schannel.c b/source4/librpc/rpc/dcerpc_schannel.c
index 0e218c478f..7cd2d1654f 100644
--- a/source4/librpc/rpc/dcerpc_schannel.c
+++ b/source4/librpc/rpc/dcerpc_schannel.c
@@ -227,7 +227,7 @@ static NTSTATUS dcerpc_schannel_update(struct gensec_security *gensec_security,
NTSTATUS dcerpc_schannel_session_info(struct gensec_security *gensec_security,
struct auth_session_info **session_info)
{
- (*session_info) = talloc_p(gensec_security, struct auth_session_info);
+ (*session_info) = talloc(gensec_security, struct auth_session_info);
NT_STATUS_HAVE_NO_MEMORY(*session_info);
ZERO_STRUCTP(*session_info);
@@ -271,7 +271,7 @@ static NTSTATUS dcerpc_schannel_start(struct gensec_security *gensec_security)
{
struct dcerpc_schannel_state *dce_schan_state;
- dce_schan_state = talloc_p(gensec_security, struct dcerpc_schannel_state);
+ dce_schan_state = talloc(gensec_security, struct dcerpc_schannel_state);
if (!dce_schan_state) {
return NT_STATUS_NO_MEMORY;
}
@@ -470,7 +470,7 @@ NTSTATUS dcerpc_bind_auth_schannel(struct dcerpc_pipe *p,
NTSTATUS status;
int chan_type = 0;
struct creds_CredentialState *creds;
- creds = talloc_p(p, struct creds_CredentialState);
+ creds = talloc(p, struct creds_CredentialState);
if (!creds) {
return NT_STATUS_NO_MEMORY;
}
diff --git a/source4/librpc/rpc/dcerpc_smb.c b/source4/librpc/rpc/dcerpc_smb.c
index 14e9fe3a9c..8d049ad967 100644
--- a/source4/librpc/rpc/dcerpc_smb.c
+++ b/source4/librpc/rpc/dcerpc_smb.c
@@ -123,7 +123,7 @@ static NTSTATUS send_read_request_continue(struct dcerpc_connection *c, DATA_BLO
struct smb_read_state *state;
struct smbcli_request *req;
- state = talloc_p(smb, struct smb_read_state);
+ state = talloc(smb, struct smb_read_state);
if (state == NULL) {
return NT_STATUS_NO_MEMORY;
}
@@ -144,7 +144,7 @@ static NTSTATUS send_read_request_continue(struct dcerpc_connection *c, DATA_BLO
memcpy(state->data.data, blob->data, blob->length);
}
- state->io = talloc_p(state, union smb_read);
+ state->io = talloc(state, union smb_read);
io = state->io;
io->generic.level = RAW_READ_READX;
@@ -222,13 +222,13 @@ static NTSTATUS smb_send_trans_request(struct dcerpc_connection *c, DATA_BLOB *b
uint16 setup[2];
struct smb_trans_state *state;
- state = talloc_p(smb, struct smb_trans_state);
+ state = talloc(smb, struct smb_trans_state);
if (state == NULL) {
return NT_STATUS_NO_MEMORY;
}
state->c = c;
- state->trans = talloc_p(state, struct smb_trans2);
+ state->trans = talloc(state, struct smb_trans2);
trans = state->trans;
trans->in.data = *blob;
@@ -418,7 +418,7 @@ NTSTATUS dcerpc_pipe_open_smb(struct dcerpc_connection *c,
/* Over-ride the default session key with the SMB session key */
c->security_state.session_key = smb_session_key;
- smb = talloc_p(c, struct smb_private);
+ smb = talloc(c, struct smb_private);
if (smb == NULL) {
return NT_STATUS_NO_MEMORY;
}
diff --git a/source4/librpc/rpc/dcerpc_sock.c b/source4/librpc/rpc/dcerpc_sock.c
index a01832764d..9fae7232ec 100644
--- a/source4/librpc/rpc/dcerpc_sock.c
+++ b/source4/librpc/rpc/dcerpc_sock.c
@@ -237,7 +237,7 @@ static NTSTATUS sock_send_request(struct dcerpc_connection *p, DATA_BLOB *data,
return NT_STATUS_CONNECTION_DISCONNECTED;
}
- blob = talloc_p(sock, struct sock_blob);
+ blob = talloc(sock, struct sock_blob);
if (blob == NULL) {
return NT_STATUS_NO_MEMORY;
}
@@ -302,7 +302,7 @@ static NTSTATUS dcerpc_pipe_open_socket(struct dcerpc_connection *c,
struct fd_event fde;
NTSTATUS status;
- sock = talloc_p(c, struct sock_private);
+ sock = talloc(c, struct sock_private);
if (!sock) {
return NT_STATUS_NO_MEMORY;
}
diff --git a/source4/librpc/rpc/dcerpc_util.c b/source4/librpc/rpc/dcerpc_util.c
index 7307b44cb8..a05ad7c897 100644
--- a/source4/librpc/rpc/dcerpc_util.c
+++ b/source4/librpc/rpc/dcerpc_util.c
@@ -324,7 +324,7 @@ NTSTATUS dcerpc_parse_binding(TALLOC_CTX *mem_ctx, const char *s, struct dcerpc_
comma_count = count_chars(options, ',');
- b->options = talloc_array_p(mem_ctx, const char *, comma_count+2);
+ b->options = talloc_array(mem_ctx, const char *, comma_count+2);
if (!b->options) {
return NT_STATUS_NO_MEMORY;
}
@@ -631,7 +631,7 @@ NTSTATUS dcerpc_binding_build_tower(TALLOC_CTX *mem_ctx, struct dcerpc_binding *
}
tower->num_floors = 2 + num_protocols;
- tower->floors = talloc_array_p(mem_ctx, struct epm_floor, tower->num_floors);
+ tower->floors = talloc_array(mem_ctx, struct epm_floor, tower->num_floors);
/* Floor 0 */
tower->floors[0].lhs.protocol = EPM_PROTOCOL_UUID;