summaryrefslogtreecommitdiff
path: root/source3/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source3/lib')
-rw-r--r--source3/lib/eventlog/eventlog.c10
-rw-r--r--source3/lib/messages_local.c5
-rw-r--r--source3/lib/secdesc.c14
-rw-r--r--source3/lib/sharesec.c2
-rw-r--r--source3/lib/util_reg_api.c6
-rw-r--r--source3/lib/util_sid.c6
6 files changed, 20 insertions, 23 deletions
diff --git a/source3/lib/eventlog/eventlog.c b/source3/lib/eventlog/eventlog.c
index c218467c47..ea7cb6d9b1 100644
--- a/source3/lib/eventlog/eventlog.c
+++ b/source3/lib/eventlog/eventlog.c
@@ -691,7 +691,7 @@ struct eventlog_Record_tdb *evlog_pull_record_tdb(TALLOC_CTX *mem_ctx,
blob = data_blob_const(data.dptr, data.dsize);
- ndr_err = ndr_pull_struct_blob(&blob, mem_ctx, NULL, r,
+ ndr_err = ndr_pull_struct_blob(&blob, mem_ctx, r,
(ndr_pull_flags_fn_t)ndr_pull_eventlog_Record_tdb);
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
@@ -741,7 +741,7 @@ struct EVENTLOGRECORD *evlog_pull_record(TALLOC_CTX *mem_ctx,
return NULL;
}
- r->Length = r->Length2 = ndr_size_EVENTLOGRECORD(r, NULL, 0);
+ r->Length = r->Length2 = ndr_size_EVENTLOGRECORD(r, 0);
return r;
}
@@ -785,7 +785,7 @@ NTSTATUS evlog_push_record_tdb(TALLOC_CTX *mem_ctx,
/* read */
r->record_number = tdb_fetch_int32(tdb, EVT_NEXT_RECORD);
- ndr_err = ndr_push_struct_blob(&blob, mem_ctx, NULL, r,
+ ndr_err = ndr_push_struct_blob(&blob, mem_ctx, r,
(ndr_push_flags_fn_t)ndr_push_eventlog_Record_tdb);
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
tdb_unlock_bystring(tdb, EVT_NEXT_RECORD);
@@ -1007,7 +1007,7 @@ NTSTATUS evlog_convert_tdb_to_evt(TALLOC_CTX *mem_ctx,
goto done;
}
- endoffset += ndr_size_EVENTLOGRECORD(&e, NULL, 0);
+ endoffset += ndr_size_EVENTLOGRECORD(&e, 0);
ADD_TO_ARRAY(mem_ctx, struct EVENTLOGRECORD, e, &evt.records, &num_records);
count++;
@@ -1034,7 +1034,7 @@ NTSTATUS evlog_convert_tdb_to_evt(TALLOC_CTX *mem_ctx,
NDR_PRINT_DEBUG(EVENTLOGEOF, &evt.eof);
}
- ndr_err = ndr_push_struct_blob(&blob, mem_ctx, NULL, &evt,
+ ndr_err = ndr_push_struct_blob(&blob, mem_ctx, &evt,
(ndr_push_flags_fn_t)ndr_push_EVENTLOG_EVT_FILE);
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
status = ndr_map_error2ntstatus(ndr_err);
diff --git a/source3/lib/messages_local.c b/source3/lib/messages_local.c
index 21910b1e65..15b2e47661 100644
--- a/source3/lib/messages_local.c
+++ b/source3/lib/messages_local.c
@@ -201,7 +201,7 @@ static NTSTATUS messaging_tdb_fetch(TDB_CONTEXT *msg_tdb,
blob = data_blob_const(data.dptr, data.dsize);
ndr_err = ndr_pull_struct_blob(
- &blob, result, NULL, result,
+ &blob, result, result,
(ndr_pull_flags_fn_t)ndr_pull_messaging_array);
SAFE_FREE(data.dptr);
@@ -243,8 +243,7 @@ static NTSTATUS messaging_tdb_store(TDB_CONTEXT *msg_tdb,
return NT_STATUS_NO_MEMORY;
}
- ndr_err = ndr_push_struct_blob(
- &blob, mem_ctx, NULL, array,
+ ndr_err = ndr_push_struct_blob(&blob, mem_ctx, array,
(ndr_push_flags_fn_t)ndr_push_messaging_array);
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
diff --git a/source3/lib/secdesc.c b/source3/lib/secdesc.c
index f5a0039ec7..7f28c87886 100644
--- a/source3/lib/secdesc.c
+++ b/source3/lib/secdesc.c
@@ -206,11 +206,11 @@ SEC_DESC *make_sec_desc(TALLOC_CTX *ctx,
}
if (dst->owner_sid != NULL) {
- offset += ndr_size_dom_sid(dst->owner_sid, NULL, 0);
+ offset += ndr_size_dom_sid(dst->owner_sid, 0);
}
if (dst->group_sid != NULL) {
- offset += ndr_size_dom_sid(dst->group_sid, NULL, 0);
+ offset += ndr_size_dom_sid(dst->group_sid, 0);
}
*sd_size = (size_t)offset;
@@ -249,7 +249,7 @@ NTSTATUS marshall_sec_desc(TALLOC_CTX *mem_ctx,
enum ndr_err_code ndr_err;
ndr_err = ndr_push_struct_blob(
- &blob, mem_ctx, NULL, secdesc,
+ &blob, mem_ctx, secdesc,
(ndr_push_flags_fn_t)ndr_push_security_descriptor);
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
@@ -275,7 +275,7 @@ NTSTATUS marshall_sec_desc_buf(TALLOC_CTX *mem_ctx,
enum ndr_err_code ndr_err;
ndr_err = ndr_push_struct_blob(
- &blob, mem_ctx, NULL, secdesc_buf,
+ &blob, mem_ctx, secdesc_buf,
(ndr_push_flags_fn_t)ndr_push_sec_desc_buf);
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
@@ -310,8 +310,7 @@ NTSTATUS unmarshall_sec_desc(TALLOC_CTX *mem_ctx, uint8 *data, size_t len,
blob = data_blob_const(data, len);
- ndr_err = ndr_pull_struct_blob(
- &blob, result, NULL, result,
+ ndr_err = ndr_pull_struct_blob(&blob, result, result,
(ndr_pull_flags_fn_t)ndr_pull_security_descriptor);
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
@@ -347,8 +346,7 @@ NTSTATUS unmarshall_sec_desc_buf(TALLOC_CTX *mem_ctx, uint8_t *data, size_t len,
blob = data_blob_const(data, len);
- ndr_err = ndr_pull_struct_blob(
- &blob, result, NULL, result,
+ ndr_err = ndr_pull_struct_blob(&blob, result, result,
(ndr_pull_flags_fn_t)ndr_pull_sec_desc_buf);
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
diff --git a/source3/lib/sharesec.c b/source3/lib/sharesec.c
index eef5f39fc0..a1a543e6a1 100644
--- a/source3/lib/sharesec.c
+++ b/source3/lib/sharesec.c
@@ -303,7 +303,7 @@ SEC_DESC *get_share_security( TALLOC_CTX *ctx, const char *servicename,
}
if (psd) {
- *psize = ndr_size_security_descriptor(psd, NULL, 0);
+ *psize = ndr_size_security_descriptor(psd, 0);
} else {
return get_share_security_default(ctx, psize,
GENERIC_ALL_ACCESS);
diff --git a/source3/lib/util_reg_api.c b/source3/lib/util_reg_api.c
index 5f9eb85323..1616d24107 100644
--- a/source3/lib/util_reg_api.c
+++ b/source3/lib/util_reg_api.c
@@ -110,7 +110,7 @@ WERROR registry_pull_value(TALLOC_CTX *mem_ctx,
blob = data_blob_const(data, length);
- if (!pull_reg_multi_sz(mem_ctx, NULL, &blob, &vals)) {
+ if (!pull_reg_multi_sz(mem_ctx, &blob, &vals)) {
err = WERR_NOMEM;
goto error;
}
@@ -156,7 +156,7 @@ WERROR registry_push_value(TALLOC_CTX *mem_ctx,
}
case REG_SZ:
case REG_EXPAND_SZ: {
- if (!push_reg_sz(mem_ctx, NULL, presult, value->v.sz.str))
+ if (!push_reg_sz(mem_ctx, presult, value->v.sz.str))
{
return WERR_NOMEM;
}
@@ -178,7 +178,7 @@ WERROR registry_push_value(TALLOC_CTX *mem_ctx,
}
array[i] = NULL;
- if (!push_reg_multi_sz(mem_ctx, NULL, presult, array)) {
+ if (!push_reg_multi_sz(mem_ctx, presult, array)) {
talloc_free(array);
return WERR_NOMEM;
}
diff --git a/source3/lib/util_sid.c b/source3/lib/util_sid.c
index c6c79a2e66..354b14e14a 100644
--- a/source3/lib/util_sid.c
+++ b/source3/lib/util_sid.c
@@ -396,7 +396,7 @@ bool sid_linearize(char *outbuf, size_t len, const DOM_SID *sid)
{
size_t i;
- if (len < ndr_size_dom_sid(sid, NULL, 0))
+ if (len < ndr_size_dom_sid(sid, 0))
return False;
SCVAL(outbuf,0,sid->sid_rev_num);
@@ -538,7 +538,7 @@ char *sid_binstring(TALLOC_CTX *mem_ctx, const DOM_SID *sid)
{
uint8_t *buf;
char *s;
- int len = ndr_size_dom_sid(sid, NULL, 0);
+ int len = ndr_size_dom_sid(sid, 0);
buf = talloc_array(mem_ctx, uint8_t, len);
if (!buf) {
return NULL;
@@ -557,7 +557,7 @@ char *sid_binstring(TALLOC_CTX *mem_ctx, const DOM_SID *sid)
char *sid_binstring_hex(const DOM_SID *sid)
{
char *buf, *s;
- int len = ndr_size_dom_sid(sid, NULL, 0);
+ int len = ndr_size_dom_sid(sid, 0);
buf = (char *)SMB_MALLOC(len);
if (!buf)
return NULL;