librpc:ndr: Introduce ‘ndr_flags_type’ type
authorJoseph Sutton <josephsutton@catalyst.net.nz>
Fri, 27 Oct 2023 01:41:17 +0000 (14:41 +1300)
committerAndrew Bartlett <abartlet@samba.org>
Wed, 1 Nov 2023 20:10:45 +0000 (20:10 +0000)
Instead of ‘int’ or ‘uint32_t’, neither of which convey much meaning,
consistently use a newly added type to hold NDR_ flags.

Update the NDR 4.0.0 ABI.

Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
70 files changed:
lib/fuzzing/fuzz_ndr_X.c
libcli/nbt/nbtname.c
librpc/ABI/ndr-4.0.0.sigs
librpc/ndr/libndr.h
librpc/ndr/ndr.c
librpc/ndr/ndr_auth.c
librpc/ndr/ndr_auth.h
librpc/ndr/ndr_backupkey.c
librpc/ndr/ndr_backupkey.h
librpc/ndr/ndr_basic.c
librpc/ndr/ndr_bkupblobs.c
librpc/ndr/ndr_cab.c
librpc/ndr/ndr_dcerpc.c
librpc/ndr/ndr_dns.c
librpc/ndr/ndr_dns.h
librpc/ndr/ndr_dns_utils.c
librpc/ndr/ndr_dns_utils.h
librpc/ndr/ndr_dnsp.c
librpc/ndr/ndr_dnsp.h
librpc/ndr/ndr_dnsserver.c
librpc/ndr/ndr_dnsserver.h
librpc/ndr/ndr_drsblobs.c
librpc/ndr/ndr_drsblobs.h
librpc/ndr/ndr_drsuapi.c
librpc/ndr/ndr_frsrpc.c
librpc/ndr/ndr_frsrpc.h
librpc/ndr/ndr_krb5pac.c
librpc/ndr/ndr_nbt.c
librpc/ndr/ndr_nbt.h
librpc/ndr/ndr_negoex.c
librpc/ndr/ndr_negoex.h
librpc/ndr/ndr_netlogon.c
librpc/ndr/ndr_netlogon.h
librpc/ndr/ndr_ntlmssp.c
librpc/ndr/ndr_ntlmssp.h
librpc/ndr/ndr_ntprinting.c
librpc/ndr/ndr_ntprinting.h
librpc/ndr/ndr_orpc.c
librpc/ndr/ndr_preg.c
librpc/ndr/ndr_preg.h
librpc/ndr/ndr_sec_helper.c
librpc/ndr/ndr_spoolss_buf.c
librpc/ndr/ndr_spoolss_buf.h
librpc/ndr/ndr_string.c
librpc/ndr/ndr_witness.c
librpc/ndr/ndr_witness.h
librpc/ndr/ndr_wmi.h
librpc/ndr/ndr_xattr.c
librpc/ndr/ndr_xattr.h
librpc/rpc/dcerpc_pkt_auth.c
librpc/rpc/dcerpc_util.c
librpc/rpc/dcesrv_core.c
librpc/rpc/dcesrv_core.h
librpc/rpc/rpc_common.h
librpc/tests/test_ndr_string.c
librpc/tools/ndrdump.c
pidl/lib/Parse/Pidl/NDR.pm
pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm
pidl/lib/Parse/Pidl/Samba4/Python.pm
pidl/lib/Parse/Pidl/Typelist.pm
source3/librpc/ndr/ndr_ads.c
source3/libsmb/cliquota.c
source3/rpc_client/cli_pipe.c
source3/rpc_client/wsp_cli.c
source3/winbindd/winbindd_dual_ndr.c
source4/lib/messaging/messaging.c
source4/librpc/rpc/dcerpc.c
source4/torture/ndr/ndr.c
source4/torture/ndr/ndr.h
source4/torture/rpc/iremotewinspool.c

index 322abea14a3ed1d4e5606dd4b928c66131d41254..16109cccb2b701f69725b01a7a196eac6103a6fb 100644 (file)
@@ -152,7 +152,7 @@ static void ndr_print_nothing(struct ndr_print *ndr, const char *format, ...)
 
 int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
        uint8_t type;
-       int pull_push_print_flags;
+       ndr_flags_type pull_push_print_flags;
        uint16_t fuzz_packet_flags, function;
        TALLOC_CTX *mem_ctx = NULL;
        libndr_flags ndr_flags = 0;
index 1881e463635ddf2652544f02486a79a514dd4524..a2b0d346c265fd501d0b753eb0635502a63a8969 100644 (file)
@@ -106,7 +106,7 @@ static uint8_t *compress_name(TALLOC_CTX *mem_ctx,
 /**
   pull a nbt name from the wire
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_nbt_name(struct ndr_pull *ndr, int ndr_flags, struct nbt_name *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_nbt_name(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct nbt_name *r)
 {
        uint8_t *scope;
        char *cname;
@@ -155,7 +155,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_nbt_name(struct ndr_pull *ndr, int ndr_flags
 /**
   push a nbt name to the wire
 */
-_PUBLIC_ enum ndr_err_code ndr_push_nbt_name(struct ndr_push *ndr, int ndr_flags, const struct nbt_name *r)
+_PUBLIC_ enum ndr_err_code ndr_push_nbt_name(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct nbt_name *r)
 {
        uint8_t *cname, *fullname;
        enum ndr_err_code ndr_err;
@@ -326,7 +326,7 @@ _PUBLIC_ char *nbt_name_string(TALLOC_CTX *mem_ctx, const struct nbt_name *name)
 /**
   pull a nbt name, WINS Replication uses another on wire format for nbt name
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_wrepl_nbt_name(struct ndr_pull *ndr, int ndr_flags, struct nbt_name **_r)
+_PUBLIC_ enum ndr_err_code ndr_pull_wrepl_nbt_name(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct nbt_name **_r)
 {
        struct nbt_name *r;
        uint8_t *namebuf;
@@ -400,7 +400,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_wrepl_nbt_name(struct ndr_pull *ndr, int ndr
 /**
   push a nbt name, WINS Replication uses another on wire format for nbt name
 */
-_PUBLIC_ enum ndr_err_code ndr_push_wrepl_nbt_name(struct ndr_push *ndr, int ndr_flags, const struct nbt_name *r)
+_PUBLIC_ enum ndr_err_code ndr_push_wrepl_nbt_name(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct nbt_name *r)
 {
        uint8_t *namebuf;
        uint32_t namebuf_len;
@@ -478,7 +478,7 @@ _PUBLIC_ void ndr_print_wrepl_nbt_name(struct ndr_print *ndr, const char *name,
        talloc_free(s);
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_nbt_qtype(struct ndr_push *ndr, int ndr_flags, enum nbt_qtype r)
+_PUBLIC_ enum ndr_err_code ndr_push_nbt_qtype(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum nbt_qtype r)
 {
        /* For WACK replies, we need to send NBT_QTYPE_NETBIOS on the wire. */
        NDR_CHECK(ndr_push_enum_uint16(ndr, NDR_SCALARS, (r == NBT_QTYPE_WACK) ? NBT_QTYPE_NETBIOS : r));
index 0eefdc90fd75250abc42283ee2ac1c4881ca7ba6..f88ca733aa7499e2eedc33c544b2728607affd02 100644 (file)
@@ -18,7 +18,7 @@ ndr_align_size: size_t (uint32_t, size_t)
 ndr_charset_length: uint32_t (const void *, charset_t)
 ndr_check_array_size: enum ndr_err_code (struct ndr_pull *, const void *, uint32_t)
 ndr_check_padding: void (struct ndr_pull *, size_t)
-ndr_check_pipe_chunk_trailer: enum ndr_err_code (struct ndr_pull *, int, uint32_t)
+ndr_check_pipe_chunk_trailer: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint32_t)
 ndr_check_steal_array_length: enum ndr_err_code (struct ndr_pull *, const void *, uint32_t)
 ndr_check_steal_array_size: enum ndr_err_code (struct ndr_pull *, const void *, uint32_t)
 ndr_check_string_terminator: enum ndr_err_code (struct ndr_pull *, uint32_t, uint32_t)
@@ -49,8 +49,8 @@ ndr_print_debugc_helper: void (struct ndr_print *, const char *, ...)
 ndr_print_dlong: void (struct ndr_print *, const char *, int64_t)
 ndr_print_double: void (struct ndr_print *, const char *, double)
 ndr_print_enum: void (struct ndr_print *, const char *, const char *, const char *, uint32_t)
-ndr_print_function_debug: void (ndr_print_function_t, const char *, int, void *)
-ndr_print_function_string: char *(TALLOC_CTX *, ndr_print_function_t, const char *, int, void *)
+ndr_print_function_debug: void (ndr_print_function_t, const char *, ndr_flags_type, void *)
+ndr_print_function_string: char *(TALLOC_CTX *, ndr_print_function_t, const char *, ndr_flags_type, void *)
 ndr_print_gid_t: void (struct ndr_print *, const char *, gid_t)
 ndr_print_hyper: void (struct ndr_print *, const char *, uint64_t)
 ndr_print_int16: void (struct ndr_print *, const char *, int16_t)
@@ -94,46 +94,46 @@ ndr_print_union_string: char *(TALLOC_CTX *, ndr_print_fn_t, const char *, uint3
 ndr_print_winreg_Data: void (struct ndr_print *, const char *, const union winreg_Data *)
 ndr_print_winreg_Data_GPO: void (struct ndr_print *, const char *, const union winreg_Data_GPO *)
 ndr_print_winreg_Type: void (struct ndr_print *, const char *, enum winreg_Type)
-ndr_pull_DATA_BLOB: enum ndr_err_code (struct ndr_pull *, int, DATA_BLOB *)
-ndr_pull_GUID: enum ndr_err_code (struct ndr_pull *, int, struct GUID *)
-ndr_pull_HRESULT: enum ndr_err_code (struct ndr_pull *, int, HRESULT *)
-ndr_pull_KRB5_EDATA_NTSTATUS: enum ndr_err_code (struct ndr_pull *, int, struct KRB5_EDATA_NTSTATUS *)
-ndr_pull_NTSTATUS: enum ndr_err_code (struct ndr_pull *, int, NTSTATUS *)
-ndr_pull_NTTIME: enum ndr_err_code (struct ndr_pull *, int, NTTIME *)
-ndr_pull_NTTIME_1sec: enum ndr_err_code (struct ndr_pull *, int, NTTIME *)
-ndr_pull_NTTIME_hyper: enum ndr_err_code (struct ndr_pull *, int, NTTIME *)
-ndr_pull_WERROR: enum ndr_err_code (struct ndr_pull *, int, WERROR *)
+ndr_pull_DATA_BLOB: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, DATA_BLOB *)
+ndr_pull_GUID: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, struct GUID *)
+ndr_pull_HRESULT: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, HRESULT *)
+ndr_pull_KRB5_EDATA_NTSTATUS: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, struct KRB5_EDATA_NTSTATUS *)
+ndr_pull_NTSTATUS: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, NTSTATUS *)
+ndr_pull_NTTIME: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, NTTIME *)
+ndr_pull_NTTIME_1sec: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, NTTIME *)
+ndr_pull_NTTIME_hyper: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, NTTIME *)
+ndr_pull_WERROR: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, WERROR *)
 ndr_pull_advance: enum ndr_err_code (struct ndr_pull *, uint32_t)
 ndr_pull_align: enum ndr_err_code (struct ndr_pull *, size_t)
 ndr_pull_append: enum ndr_err_code (struct ndr_pull *, DATA_BLOB *)
 ndr_pull_array_length: enum ndr_err_code (struct ndr_pull *, const void *)
 ndr_pull_array_size: enum ndr_err_code (struct ndr_pull *, const void *)
-ndr_pull_array_uint8: enum ndr_err_code (struct ndr_pull *, int, uint8_t *, uint32_t)
+ndr_pull_array_uint8: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint8_t *, uint32_t)
 ndr_pull_bytes: enum ndr_err_code (struct ndr_pull *, uint8_t *, uint32_t)
-ndr_pull_charset: enum ndr_err_code (struct ndr_pull *, int, const char **, uint32_t, uint8_t, charset_t)
-ndr_pull_charset_to_null: enum ndr_err_code (struct ndr_pull *, int, const char **, uint32_t, uint8_t, charset_t)
-ndr_pull_dlong: enum ndr_err_code (struct ndr_pull *, int, int64_t *)
-ndr_pull_double: enum ndr_err_code (struct ndr_pull *, int, double *)
-ndr_pull_enum_uint16: enum ndr_err_code (struct ndr_pull *, int, uint16_t *)
-ndr_pull_enum_uint1632: enum ndr_err_code (struct ndr_pull *, int, uint16_t *)
-ndr_pull_enum_uint32: enum ndr_err_code (struct ndr_pull *, int, uint32_t *)
-ndr_pull_enum_uint8: enum ndr_err_code (struct ndr_pull *, int, uint8_t *)
+ndr_pull_charset: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, const char **, uint32_t, uint8_t, charset_t)
+ndr_pull_charset_to_null: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, const char **, uint32_t, uint8_t, charset_t)
+ndr_pull_dlong: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, int64_t *)
+ndr_pull_double: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, double *)
+ndr_pull_enum_uint16: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint16_t *)
+ndr_pull_enum_uint1632: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint16_t *)
+ndr_pull_enum_uint32: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint32_t *)
+ndr_pull_enum_uint8: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint8_t *)
 ndr_pull_generic_ptr: enum ndr_err_code (struct ndr_pull *, uint32_t *)
 ndr_pull_get_relative_base_offset: uint32_t (struct ndr_pull *)
-ndr_pull_gid_t: enum ndr_err_code (struct ndr_pull *, int, gid_t *)
-ndr_pull_hyper: enum ndr_err_code (struct ndr_pull *, int, uint64_t *)
+ndr_pull_gid_t: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, gid_t *)
+ndr_pull_hyper: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint64_t *)
 ndr_pull_init_blob: struct ndr_pull *(const DATA_BLOB *, TALLOC_CTX *)
-ndr_pull_int16: enum ndr_err_code (struct ndr_pull *, int, int16_t *)
-ndr_pull_int32: enum ndr_err_code (struct ndr_pull *, int, int32_t *)
-ndr_pull_int64: enum ndr_err_code (struct ndr_pull *, int, int64_t *)
-ndr_pull_int8: enum ndr_err_code (struct ndr_pull *, int, int8_t *)
-ndr_pull_ipv4address: enum ndr_err_code (struct ndr_pull *, int, const char **)
-ndr_pull_ipv6address: enum ndr_err_code (struct ndr_pull *, int, const char **)
-ndr_pull_ndr_syntax_id: enum ndr_err_code (struct ndr_pull *, int, struct ndr_syntax_id *)
-ndr_pull_netr_SamDatabaseID: enum ndr_err_code (struct ndr_pull *, int, enum netr_SamDatabaseID *)
-ndr_pull_netr_SchannelType: enum ndr_err_code (struct ndr_pull *, int, enum netr_SchannelType *)
-ndr_pull_pointer: enum ndr_err_code (struct ndr_pull *, int, void **)
-ndr_pull_policy_handle: enum ndr_err_code (struct ndr_pull *, int, struct policy_handle *)
+ndr_pull_int16: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, int16_t *)
+ndr_pull_int32: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, int32_t *)
+ndr_pull_int64: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, int64_t *)
+ndr_pull_int8: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, int8_t *)
+ndr_pull_ipv4address: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, const char **)
+ndr_pull_ipv6address: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, const char **)
+ndr_pull_ndr_syntax_id: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, struct ndr_syntax_id *)
+ndr_pull_netr_SamDatabaseID: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, enum netr_SamDatabaseID *)
+ndr_pull_netr_SchannelType: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, enum netr_SchannelType *)
+ndr_pull_pointer: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, void **)
+ndr_pull_policy_handle: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, struct policy_handle *)
 ndr_pull_pop: enum ndr_err_code (struct ndr_pull *)
 ndr_pull_ref_ptr: enum ndr_err_code (struct ndr_pull *, uint32_t *)
 ndr_pull_relative_ptr1: enum ndr_err_code (struct ndr_pull *, const void *, uint32_t)
@@ -144,72 +144,72 @@ ndr_pull_set_switch_value: enum ndr_err_code (struct ndr_pull *, const void *, u
 ndr_pull_setup_relative_base_offset1: enum ndr_err_code (struct ndr_pull *, const void *, uint32_t)
 ndr_pull_setup_relative_base_offset2: enum ndr_err_code (struct ndr_pull *, const void *)
 ndr_pull_steal_switch_value: enum ndr_err_code (struct ndr_pull *, const void *, uint32_t *)
-ndr_pull_string: enum ndr_err_code (struct ndr_pull *, int, const char **)
-ndr_pull_string_array: enum ndr_err_code (struct ndr_pull *, int, const char ***)
+ndr_pull_string: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, const char **)
+ndr_pull_string_array: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, const char ***)
 ndr_pull_struct_blob: enum ndr_err_code (const DATA_BLOB *, TALLOC_CTX *, void *, ndr_pull_flags_fn_t)
 ndr_pull_struct_blob_all: enum ndr_err_code (const DATA_BLOB *, TALLOC_CTX *, void *, ndr_pull_flags_fn_t)
 ndr_pull_struct_blob_all_noalloc: enum ndr_err_code (const DATA_BLOB *, void *, ndr_pull_flags_fn_t)
 ndr_pull_struct_blob_noalloc: enum ndr_err_code (const uint8_t *, size_t, void *, ndr_pull_flags_fn_t, size_t *)
 ndr_pull_subcontext_end: enum ndr_err_code (struct ndr_pull *, struct ndr_pull *, size_t, ssize_t)
 ndr_pull_subcontext_start: enum ndr_err_code (struct ndr_pull *, struct ndr_pull **, size_t, ssize_t)
-ndr_pull_svcctl_ServerType: enum ndr_err_code (struct ndr_pull *, int, uint32_t *)
-ndr_pull_time_t: enum ndr_err_code (struct ndr_pull *, int, time_t *)
-ndr_pull_timespec: enum ndr_err_code (struct ndr_pull *, int, struct timespec *)
-ndr_pull_timeval: enum ndr_err_code (struct ndr_pull *, int, struct timeval *)
+ndr_pull_svcctl_ServerType: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint32_t *)
+ndr_pull_time_t: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, time_t *)
+ndr_pull_timespec: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, struct timespec *)
+ndr_pull_timeval: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, struct timeval *)
 ndr_pull_trailer_align: enum ndr_err_code (struct ndr_pull *, size_t)
-ndr_pull_udlong: enum ndr_err_code (struct ndr_pull *, int, uint64_t *)
-ndr_pull_udlongr: enum ndr_err_code (struct ndr_pull *, int, uint64_t *)
-ndr_pull_uid_t: enum ndr_err_code (struct ndr_pull *, int, uid_t *)
-ndr_pull_uint16: enum ndr_err_code (struct ndr_pull *, int, uint16_t *)
-ndr_pull_uint1632: enum ndr_err_code (struct ndr_pull *, int, uint16_t *)
-ndr_pull_uint32: enum ndr_err_code (struct ndr_pull *, int, uint32_t *)
-ndr_pull_uint3264: enum ndr_err_code (struct ndr_pull *, int, uint32_t *)
-ndr_pull_uint8: enum ndr_err_code (struct ndr_pull *, int, uint8_t *)
+ndr_pull_udlong: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint64_t *)
+ndr_pull_udlongr: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint64_t *)
+ndr_pull_uid_t: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uid_t *)
+ndr_pull_uint16: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint16_t *)
+ndr_pull_uint1632: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint16_t *)
+ndr_pull_uint32: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint32_t *)
+ndr_pull_uint3264: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint32_t *)
+ndr_pull_uint8: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint8_t *)
 ndr_pull_union_align: enum ndr_err_code (struct ndr_pull *, size_t)
 ndr_pull_union_blob: enum ndr_err_code (const DATA_BLOB *, TALLOC_CTX *, void *, uint32_t, ndr_pull_flags_fn_t)
 ndr_pull_union_blob_all: enum ndr_err_code (const DATA_BLOB *, TALLOC_CTX *, void *, uint32_t, ndr_pull_flags_fn_t)
-ndr_pull_winreg_Data: enum ndr_err_code (struct ndr_pull *, int, union winreg_Data *)
-ndr_pull_winreg_Data_GPO: enum ndr_err_code (struct ndr_pull *, int, union winreg_Data_GPO *)
-ndr_pull_winreg_Type: enum ndr_err_code (struct ndr_pull *, int, enum winreg_Type *)
-ndr_push_DATA_BLOB: enum ndr_err_code (struct ndr_push *, int, DATA_BLOB)
-ndr_push_GUID: enum ndr_err_code (struct ndr_push *, int, const struct GUID *)
-ndr_push_HRESULT: enum ndr_err_code (struct ndr_push *, int, HRESULT)
-ndr_push_KRB5_EDATA_NTSTATUS: enum ndr_err_code (struct ndr_push *, int, const struct KRB5_EDATA_NTSTATUS *)
-ndr_push_NTSTATUS: enum ndr_err_code (struct ndr_push *, int, NTSTATUS)
-ndr_push_NTTIME: enum ndr_err_code (struct ndr_push *, int, NTTIME)
-ndr_push_NTTIME_1sec: enum ndr_err_code (struct ndr_push *, int, NTTIME)
-ndr_push_NTTIME_hyper: enum ndr_err_code (struct ndr_push *, int, NTTIME)
-ndr_push_WERROR: enum ndr_err_code (struct ndr_push *, int, WERROR)
+ndr_pull_winreg_Data: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, union winreg_Data *)
+ndr_pull_winreg_Data_GPO: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, union winreg_Data_GPO *)
+ndr_pull_winreg_Type: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, enum winreg_Type *)
+ndr_push_DATA_BLOB: enum ndr_err_code (struct ndr_push *, ndr_flags_type, DATA_BLOB)
+ndr_push_GUID: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const struct GUID *)
+ndr_push_HRESULT: enum ndr_err_code (struct ndr_push *, ndr_flags_type, HRESULT)
+ndr_push_KRB5_EDATA_NTSTATUS: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const struct KRB5_EDATA_NTSTATUS *)
+ndr_push_NTSTATUS: enum ndr_err_code (struct ndr_push *, ndr_flags_type, NTSTATUS)
+ndr_push_NTTIME: enum ndr_err_code (struct ndr_push *, ndr_flags_type, NTTIME)
+ndr_push_NTTIME_1sec: enum ndr_err_code (struct ndr_push *, ndr_flags_type, NTTIME)
+ndr_push_NTTIME_hyper: enum ndr_err_code (struct ndr_push *, ndr_flags_type, NTTIME)
+ndr_push_WERROR: enum ndr_err_code (struct ndr_push *, ndr_flags_type, WERROR)
 ndr_push_align: enum ndr_err_code (struct ndr_push *, size_t)
-ndr_push_array_uint8: enum ndr_err_code (struct ndr_push *, int, const uint8_t *, uint32_t)
+ndr_push_array_uint8: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const uint8_t *, uint32_t)
 ndr_push_blob: DATA_BLOB (struct ndr_push *)
 ndr_push_bytes: enum ndr_err_code (struct ndr_push *, const uint8_t *, uint32_t)
-ndr_push_charset: enum ndr_err_code (struct ndr_push *, int, const char *, uint32_t, uint8_t, charset_t)
-ndr_push_charset_to_null: enum ndr_err_code (struct ndr_push *, int, const char *, uint32_t, uint8_t, charset_t)
-ndr_push_dlong: enum ndr_err_code (struct ndr_push *, int, int64_t)
-ndr_push_double: enum ndr_err_code (struct ndr_push *, int, double)
-ndr_push_enum_uint16: enum ndr_err_code (struct ndr_push *, int, uint16_t)
-ndr_push_enum_uint1632: enum ndr_err_code (struct ndr_push *, int, uint16_t)
-ndr_push_enum_uint32: enum ndr_err_code (struct ndr_push *, int, uint32_t)
-ndr_push_enum_uint8: enum ndr_err_code (struct ndr_push *, int, uint8_t)
+ndr_push_charset: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const char *, uint32_t, uint8_t, charset_t)
+ndr_push_charset_to_null: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const char *, uint32_t, uint8_t, charset_t)
+ndr_push_dlong: enum ndr_err_code (struct ndr_push *, ndr_flags_type, int64_t)
+ndr_push_double: enum ndr_err_code (struct ndr_push *, ndr_flags_type, double)
+ndr_push_enum_uint16: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint16_t)
+ndr_push_enum_uint1632: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint16_t)
+ndr_push_enum_uint32: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint32_t)
+ndr_push_enum_uint8: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint8_t)
 ndr_push_expand: enum ndr_err_code (struct ndr_push *, uint32_t)
 ndr_push_full_ptr: enum ndr_err_code (struct ndr_push *, const void *)
 ndr_push_get_relative_base_offset: uint32_t (struct ndr_push *)
-ndr_push_gid_t: enum ndr_err_code (struct ndr_push *, int, gid_t)
-ndr_push_hyper: enum ndr_err_code (struct ndr_push *, int, uint64_t)
+ndr_push_gid_t: enum ndr_err_code (struct ndr_push *, ndr_flags_type, gid_t)
+ndr_push_hyper: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint64_t)
 ndr_push_init_ctx: struct ndr_push *(TALLOC_CTX *)
-ndr_push_int16: enum ndr_err_code (struct ndr_push *, int, int16_t)
-ndr_push_int32: enum ndr_err_code (struct ndr_push *, int, int32_t)
-ndr_push_int64: enum ndr_err_code (struct ndr_push *, int, int64_t)
-ndr_push_int8: enum ndr_err_code (struct ndr_push *, int, int8_t)
-ndr_push_ipv4address: enum ndr_err_code (struct ndr_push *, int, const char *)
-ndr_push_ipv6address: enum ndr_err_code (struct ndr_push *, int, const char *)
-ndr_push_ndr_syntax_id: enum ndr_err_code (struct ndr_push *, int, const struct ndr_syntax_id *)
-ndr_push_netr_SamDatabaseID: enum ndr_err_code (struct ndr_push *, int, enum netr_SamDatabaseID)
-ndr_push_netr_SchannelType: enum ndr_err_code (struct ndr_push *, int, enum netr_SchannelType)
-ndr_push_pipe_chunk_trailer: enum ndr_err_code (struct ndr_push *, int, uint32_t)
-ndr_push_pointer: enum ndr_err_code (struct ndr_push *, int, void *)
-ndr_push_policy_handle: enum ndr_err_code (struct ndr_push *, int, const struct policy_handle *)
+ndr_push_int16: enum ndr_err_code (struct ndr_push *, ndr_flags_type, int16_t)
+ndr_push_int32: enum ndr_err_code (struct ndr_push *, ndr_flags_type, int32_t)
+ndr_push_int64: enum ndr_err_code (struct ndr_push *, ndr_flags_type, int64_t)
+ndr_push_int8: enum ndr_err_code (struct ndr_push *, ndr_flags_type, int8_t)
+ndr_push_ipv4address: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const char *)
+ndr_push_ipv6address: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const char *)
+ndr_push_ndr_syntax_id: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const struct ndr_syntax_id *)
+ndr_push_netr_SamDatabaseID: enum ndr_err_code (struct ndr_push *, ndr_flags_type, enum netr_SamDatabaseID)
+ndr_push_netr_SchannelType: enum ndr_err_code (struct ndr_push *, ndr_flags_type, enum netr_SchannelType)
+ndr_push_pipe_chunk_trailer: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint32_t)
+ndr_push_pointer: enum ndr_err_code (struct ndr_push *, ndr_flags_type, void *)
+ndr_push_policy_handle: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const struct policy_handle *)
 ndr_push_ref_ptr: enum ndr_err_code (struct ndr_push *)
 ndr_push_relative_ptr1: enum ndr_err_code (struct ndr_push *, const void *)
 ndr_push_relative_ptr2_end: enum ndr_err_code (struct ndr_push *, const void *)
@@ -221,36 +221,36 @@ ndr_push_setup_relative_base_offset2: enum ndr_err_code (struct ndr_push *, cons
 ndr_push_short_relative_ptr1: enum ndr_err_code (struct ndr_push *, const void *)
 ndr_push_short_relative_ptr2: enum ndr_err_code (struct ndr_push *, const void *)
 ndr_push_steal_switch_value: enum ndr_err_code (struct ndr_push *, const void *, uint32_t *)
-ndr_push_string: enum ndr_err_code (struct ndr_push *, int, const char *)
-ndr_push_string_array: enum ndr_err_code (struct ndr_push *, int, const char **)
+ndr_push_string: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const char *)
+ndr_push_string_array: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const char **)
 ndr_push_struct_blob: enum ndr_err_code (DATA_BLOB *, TALLOC_CTX *, const void *, ndr_push_flags_fn_t)
 ndr_push_struct_into_fixed_blob: enum ndr_err_code (DATA_BLOB *, const void *, ndr_push_flags_fn_t)
 ndr_push_subcontext_end: enum ndr_err_code (struct ndr_push *, struct ndr_push *, size_t, ssize_t)
 ndr_push_subcontext_start: enum ndr_err_code (struct ndr_push *, struct ndr_push **, size_t, ssize_t)
-ndr_push_svcctl_ServerType: enum ndr_err_code (struct ndr_push *, int, uint32_t)
-ndr_push_time_t: enum ndr_err_code (struct ndr_push *, int, time_t)
-ndr_push_timespec: enum ndr_err_code (struct ndr_push *, int, const struct timespec *)
-ndr_push_timeval: enum ndr_err_code (struct ndr_push *, int, const struct timeval *)
+ndr_push_svcctl_ServerType: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint32_t)
+ndr_push_time_t: enum ndr_err_code (struct ndr_push *, ndr_flags_type, time_t)
+ndr_push_timespec: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const struct timespec *)
+ndr_push_timeval: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const struct timeval *)
 ndr_push_trailer_align: enum ndr_err_code (struct ndr_push *, size_t)
-ndr_push_udlong: enum ndr_err_code (struct ndr_push *, int, uint64_t)
-ndr_push_udlongr: enum ndr_err_code (struct ndr_push *, int, uint64_t)
-ndr_push_uid_t: enum ndr_err_code (struct ndr_push *, int, uid_t)
-ndr_push_uint16: enum ndr_err_code (struct ndr_push *, int, uint16_t)
-ndr_push_uint1632: enum ndr_err_code (struct ndr_push *, int, uint16_t)
-ndr_push_uint32: enum ndr_err_code (struct ndr_push *, int, uint32_t)
-ndr_push_uint3264: enum ndr_err_code (struct ndr_push *, int, uint32_t)
-ndr_push_uint8: enum ndr_err_code (struct ndr_push *, int, uint8_t)
+ndr_push_udlong: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint64_t)
+ndr_push_udlongr: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint64_t)
+ndr_push_uid_t: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uid_t)
+ndr_push_uint16: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint16_t)
+ndr_push_uint1632: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint16_t)
+ndr_push_uint32: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint32_t)
+ndr_push_uint3264: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint32_t)
+ndr_push_uint8: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint8_t)
 ndr_push_union_align: enum ndr_err_code (struct ndr_push *, size_t)
 ndr_push_union_blob: enum ndr_err_code (DATA_BLOB *, TALLOC_CTX *, void *, uint32_t, ndr_push_flags_fn_t)
 ndr_push_unique_ptr: enum ndr_err_code (struct ndr_push *, const void *)
-ndr_push_winreg_Data: enum ndr_err_code (struct ndr_push *, int, const union winreg_Data *)
-ndr_push_winreg_Data_GPO: enum ndr_err_code (struct ndr_push *, int, const union winreg_Data_GPO *)
-ndr_push_winreg_Type: enum ndr_err_code (struct ndr_push *, int, enum winreg_Type)
+ndr_push_winreg_Data: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const union winreg_Data *)
+ndr_push_winreg_Data_GPO: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const union winreg_Data_GPO *)
+ndr_push_winreg_Type: enum ndr_err_code (struct ndr_push *, ndr_flags_type, enum winreg_Type)
 ndr_push_zero: enum ndr_err_code (struct ndr_push *, uint32_t)
 ndr_set_flags: void (libndr_flags *, libndr_flags)
-ndr_size_DATA_BLOB: uint32_t (int, const DATA_BLOB *, int)
+ndr_size_DATA_BLOB: uint32_t (int, const DATA_BLOB *, ndr_flags_type)
 ndr_size_GUID: size_t (const struct GUID *, libndr_flags)
-ndr_size_string: uint32_t (int, const char * const *, int)
+ndr_size_string: uint32_t (int, const char * const *, ndr_flags_type)
 ndr_size_string_array: size_t (const char **, uint32_t, libndr_flags)
 ndr_size_struct: size_t (const void *, libndr_flags, ndr_push_flags_fn_t)
 ndr_size_union: size_t (const void *, libndr_flags, uint32_t, ndr_push_flags_fn_t)
index 406ccd010912649c5f84a6c938f4d80ae71ab67d..8cfd05284e4ecd17da7a31eb70021b92af4af4fa 100644 (file)
@@ -56,6 +56,13 @@ typedef uint32_t libndr_flags;
 #define PRI_LIBNDR_FLAGS PRIx32
 #define PRI_LIBNDR_FLAGS_DECIMAL PRIu32
 
+/*
+* If you’re considering changing the size of this type, see also
+* $scalar_alignment in pidl/lib/Parse/Pidl/NDR.pm.
+*/
+typedef uint32_t ndr_flags_type;
+#define PRI_NDR_FLAGS_TYPE PRIx32
+
 /* this is the base structure passed to routines that
    parse MSRPC formatted data
 
@@ -340,24 +347,24 @@ enum ndr_compression_alg {
 
 #define NDR_PULL_CHECK_FLAGS(ndr, ndr_flags) do { \
        if ((ndr_flags) & ~(NDR_SCALARS|NDR_BUFFERS)) { \
-               return ndr_pull_error(ndr, NDR_ERR_FLAGS, "Invalid pull struct ndr_flags 0x%x", ndr_flags); \
+               return ndr_pull_error(ndr, NDR_ERR_FLAGS, "Invalid pull struct ndr_flags 0x%"PRI_NDR_FLAGS_TYPE, ndr_flags); \
        } \
 } while (0)
 
 #define NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags) do { \
        if ((ndr_flags) & ~(NDR_SCALARS|NDR_BUFFERS)) \
-               return ndr_push_error(ndr, NDR_ERR_FLAGS, "Invalid push struct ndr_flags 0x%x", ndr_flags); \
+               return ndr_push_error(ndr, NDR_ERR_FLAGS, "Invalid push struct ndr_flags 0x%"PRI_NDR_FLAGS_TYPE, ndr_flags); \
 } while (0)
 
 #define NDR_PULL_CHECK_FN_FLAGS(ndr, flags) do { \
        if ((flags) & ~(NDR_BOTH|NDR_SET_VALUES)) { \
-               return ndr_pull_error(ndr, NDR_ERR_FLAGS, "Invalid fn pull flags 0x%x", flags); \
+               return ndr_pull_error(ndr, NDR_ERR_FLAGS, "Invalid fn pull flags 0x%"PRI_NDR_FLAGS_TYPE, flags); \
        } \
 } while (0)
 
 #define NDR_PUSH_CHECK_FN_FLAGS(ndr, flags) do { \
        if ((flags) & ~(NDR_BOTH|NDR_SET_VALUES)) \
-               return ndr_push_error(ndr, NDR_ERR_FLAGS, "Invalid fn push flags 0x%x", flags); \
+               return ndr_push_error(ndr, NDR_ERR_FLAGS, "Invalid fn push flags 0x%"PRI_NDR_FLAGS_TYPE, flags); \
 } while (0)
 
 #define NDR_PULL_NEED_BYTES(ndr, n) do { \
@@ -506,10 +513,10 @@ enum ndr_compression_alg {
 } while(0)
 
 /* these are used when generic fn pointers are needed for ndr push/pull fns */
-typedef enum ndr_err_code (*ndr_push_flags_fn_t)(struct ndr_push *, int ndr_flags, const void *);
-typedef enum ndr_err_code (*ndr_pull_flags_fn_t)(struct ndr_pull *, int ndr_flags, void *);
+typedef enum ndr_err_code (*ndr_push_flags_fn_t)(struct ndr_push *, ndr_flags_type ndr_flags, const void *);
+typedef enum ndr_err_code (*ndr_pull_flags_fn_t)(struct ndr_pull *, ndr_flags_type ndr_flags, void *);
 typedef void (*ndr_print_fn_t)(struct ndr_print *, const char *, const void *);
-typedef void (*ndr_print_function_t)(struct ndr_print *, const char *, int, const void *);
+typedef void (*ndr_print_function_t)(struct ndr_print *, const char *, ndr_flags_type, const void *);
 
 #include "../libcli/util/error.h"
 #include "librpc/gen_ndr/misc.h"
@@ -584,15 +591,15 @@ const char *ndr_map_error2string(enum ndr_err_code ndr_err);
 
 /* FIXME: Use represent_as instead */
 struct dom_sid;
-enum ndr_err_code ndr_push_dom_sid2(struct ndr_push *ndr, int ndr_flags, const struct dom_sid *sid);
-enum ndr_err_code ndr_pull_dom_sid2(struct ndr_pull *ndr, int ndr_flags, struct dom_sid *sid);
+enum ndr_err_code ndr_push_dom_sid2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct dom_sid *sid);
+enum ndr_err_code ndr_pull_dom_sid2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dom_sid *sid);
 void ndr_print_dom_sid2(struct ndr_print *ndr, const char *name, const struct dom_sid *sid);
-enum ndr_err_code ndr_push_dom_sid28(struct ndr_push *ndr, int ndr_flags, const struct dom_sid *sid);
-enum ndr_err_code ndr_pull_dom_sid28(struct ndr_pull *ndr, int ndr_flags, struct dom_sid *sid);
+enum ndr_err_code ndr_push_dom_sid28(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct dom_sid *sid);
+enum ndr_err_code ndr_pull_dom_sid28(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dom_sid *sid);
 void ndr_print_dom_sid28(struct ndr_print *ndr, const char *name, const struct dom_sid *sid);
 size_t ndr_size_dom_sid28(const struct dom_sid *sid, libndr_flags flags);
-enum ndr_err_code ndr_push_dom_sid0(struct ndr_push *ndr, int ndr_flags, const struct dom_sid *sid);
-enum ndr_err_code ndr_pull_dom_sid0(struct ndr_pull *ndr, int ndr_flags, struct dom_sid *sid);
+enum ndr_err_code ndr_push_dom_sid0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct dom_sid *sid);
+enum ndr_err_code ndr_pull_dom_sid0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dom_sid *sid);
 void ndr_print_dom_sid0(struct ndr_print *ndr, const char *name, const struct dom_sid *sid);
 size_t ndr_size_dom_sid0(const struct dom_sid *sid, libndr_flags flags);
 void ndr_print_GUID(struct ndr_print *ndr, const char *name, const struct GUID *guid);
@@ -644,12 +651,12 @@ void ndr_print_string_helper(struct ndr_print *ndr, const char *format, ...) PRI
 bool ndr_print_debug(int level, ndr_print_fn_t fn, const char *name, void *ptr, const char *location, const char *function);
 void ndr_print_debugc(int dbgc_class, ndr_print_fn_t fn, const char *name, void *ptr);
 void ndr_print_union_debug(ndr_print_fn_t fn, const char *name, uint32_t level, void *ptr);
-void ndr_print_function_debug(ndr_print_function_t fn, const char *name, int flags, void *ptr);
+void ndr_print_function_debug(ndr_print_function_t fn, const char *name, ndr_flags_type flags, void *ptr);
 char *ndr_print_struct_string(TALLOC_CTX *mem_ctx, ndr_print_fn_t fn, const char *name, void *ptr);
 char *ndr_print_union_string(TALLOC_CTX *mem_ctx, ndr_print_fn_t fn, const char *name, uint32_t level, void *ptr);
 char *ndr_print_function_string(TALLOC_CTX *mem_ctx,
                                ndr_print_function_t fn, const char *name,
-                               int flags, void *ptr);
+                               ndr_flags_type flags, void *ptr);
 void ndr_set_flags(libndr_flags *pflags, libndr_flags new_flags);
 enum ndr_err_code _ndr_pull_error(struct ndr_pull *ndr,
                                  enum ndr_err_code ndr_err,
@@ -707,8 +714,8 @@ enum ndr_err_code ndr_get_array_length(struct ndr_pull *ndr, const void *p, uint
 enum ndr_err_code ndr_steal_array_length(struct ndr_pull *ndr, const void *p, uint32_t *length);
 enum ndr_err_code ndr_check_array_length(struct ndr_pull *ndr, const void *p, uint32_t length);
 enum ndr_err_code ndr_check_steal_array_length(struct ndr_pull *ndr, const void *p, uint32_t length);
-enum ndr_err_code ndr_push_pipe_chunk_trailer(struct ndr_push *ndr, int ndr_flags, uint32_t count);
-enum ndr_err_code ndr_check_pipe_chunk_trailer(struct ndr_pull *ndr, int ndr_flags, uint32_t count);
+enum ndr_err_code ndr_push_pipe_chunk_trailer(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t count);
+enum ndr_err_code ndr_check_pipe_chunk_trailer(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t count);
 enum ndr_err_code ndr_push_set_switch_value(struct ndr_push *ndr, const void *p, uint32_t val);
 enum ndr_err_code ndr_pull_set_switch_value(struct ndr_pull *ndr, const void *p, uint32_t val);
 enum ndr_err_code ndr_print_set_switch_value(struct ndr_print *ndr, const void *p, uint32_t val);
@@ -736,18 +743,18 @@ enum ndr_err_code ndr_pull_union_blob_all(const DATA_BLOB *blob, TALLOC_CTX *mem
 
 /* from libndr_basic.h */
 #define NDR_SCALAR_PROTO(name, type) \
-enum ndr_err_code ndr_push_ ## name(struct ndr_push *ndr, int ndr_flags, type v); \
-enum ndr_err_code ndr_pull_ ## name(struct ndr_pull *ndr, int ndr_flags, type *v); \
+enum ndr_err_code ndr_push_ ## name(struct ndr_push *ndr, ndr_flags_type ndr_flags, type v); \
+enum ndr_err_code ndr_pull_ ## name(struct ndr_pull *ndr, ndr_flags_type ndr_flags, type *v); \
 void ndr_print_ ## name(struct ndr_print *ndr, const char *var_name, type v);
 
 #define NDR_SCALAR_PTR_PROTO(name, type) \
-enum ndr_err_code ndr_push_ ## name(struct ndr_push *ndr, int ndr_flags, const type *v); \
-enum ndr_err_code ndr_pull_ ## name(struct ndr_pull *ndr, int ndr_flags, type **v); \
+enum ndr_err_code ndr_push_ ## name(struct ndr_push *ndr, ndr_flags_type ndr_flags, const type *v); \
+enum ndr_err_code ndr_pull_ ## name(struct ndr_pull *ndr, ndr_flags_type ndr_flags, type **v); \
 void ndr_print_ ## name(struct ndr_print *ndr, const char *var_name, const type *v);
 
 #define NDR_BUFFER_PROTO(name, type) \
-enum ndr_err_code ndr_push_ ## name(struct ndr_push *ndr, int ndr_flags, const type *v); \
-enum ndr_err_code ndr_pull_ ## name(struct ndr_pull *ndr, int ndr_flags, type *v); \
+enum ndr_err_code ndr_push_ ## name(struct ndr_push *ndr, ndr_flags_type ndr_flags, const type *v); \
+enum ndr_err_code ndr_pull_ ## name(struct ndr_pull *ndr, ndr_flags_type ndr_flags, type *v); \
 void ndr_print_ ## name(struct ndr_print *ndr, const char *var_name, const type *v);
 
 NDR_SCALAR_PROTO(uint8, uint8_t)
@@ -780,8 +787,8 @@ NDR_SCALAR_PROTO(ipv6address, const char *)
 NDR_SCALAR_PROTO(string, const char *)
 NDR_SCALAR_PROTO(double, double)
 
-enum ndr_err_code ndr_pull_policy_handle(struct ndr_pull *ndr, int ndr_flags, struct policy_handle *r);
-enum ndr_err_code ndr_push_policy_handle(struct ndr_push *ndr, int ndr_flags, const struct policy_handle *r);
+enum ndr_err_code ndr_pull_policy_handle(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct policy_handle *r);
+enum ndr_err_code ndr_push_policy_handle(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct policy_handle *r);
 void ndr_print_policy_handle(struct ndr_print *ndr, const char *name, const struct policy_handle *r);
 bool ndr_policy_handle_empty(const struct policy_handle *h);
 #define is_valid_policy_hnd(hnd) (!ndr_policy_handle_empty(hnd))
@@ -792,7 +799,7 @@ void ndr_check_padding(struct ndr_pull *ndr, size_t n);
 enum ndr_err_code ndr_pull_generic_ptr(struct ndr_pull *ndr, uint32_t *v);
 enum ndr_err_code ndr_pull_ref_ptr(struct ndr_pull *ndr, uint32_t *v);
 enum ndr_err_code ndr_pull_bytes(struct ndr_pull *ndr, uint8_t *data, uint32_t n);
-enum ndr_err_code ndr_pull_array_uint8(struct ndr_pull *ndr, int ndr_flags, uint8_t *data, uint32_t n);
+enum ndr_err_code ndr_pull_array_uint8(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint8_t *data, uint32_t n);
 enum ndr_err_code ndr_push_align(struct ndr_push *ndr, size_t size);
 enum ndr_err_code ndr_pull_align(struct ndr_pull *ndr, size_t size);
 enum ndr_err_code ndr_push_union_align(struct ndr_push *ndr, size_t size);
@@ -801,7 +808,7 @@ enum ndr_err_code ndr_push_trailer_align(struct ndr_push *ndr, size_t size);
 enum ndr_err_code ndr_pull_trailer_align(struct ndr_pull *ndr, size_t size);
 enum ndr_err_code ndr_push_bytes(struct ndr_push *ndr, const uint8_t *data, uint32_t n);
 enum ndr_err_code ndr_push_zero(struct ndr_push *ndr, uint32_t n);
-enum ndr_err_code ndr_push_array_uint8(struct ndr_push *ndr, int ndr_flags, const uint8_t *data, uint32_t n);
+enum ndr_err_code ndr_push_array_uint8(struct ndr_push *ndr, ndr_flags_type ndr_flags, const uint8_t *data, uint32_t n);
 enum ndr_err_code ndr_push_unique_ptr(struct ndr_push *ndr, const void *p);
 enum ndr_err_code ndr_push_full_ptr(struct ndr_push *ndr, const void *p);
 enum ndr_err_code ndr_push_ref_ptr(struct ndr_push *ndr);
@@ -814,22 +821,22 @@ void ndr_print_ptr(struct ndr_print *ndr, const char *name, const void *p);
 void ndr_print_union(struct ndr_print *ndr, const char *name, int level, const char *type);
 void ndr_print_bad_level(struct ndr_print *ndr, const char *name, uint16_t level);
 void ndr_print_array_uint8(struct ndr_print *ndr, const char *name, const uint8_t *data, uint32_t count);
-uint32_t ndr_size_DATA_BLOB(int ret, const DATA_BLOB *data, int flags);
+uint32_t ndr_size_DATA_BLOB(int ret, const DATA_BLOB *data, ndr_flags_type flags);
 
 /* strings */
 uint32_t ndr_charset_length(const void *var, charset_t chset);
 size_t ndr_string_array_size(struct ndr_push *ndr, const char *s);
-uint32_t ndr_size_string(int ret, const char * const* string, int flags);
-enum ndr_err_code ndr_pull_string_array(struct ndr_pull *ndr, int ndr_flags, const char ***_a);
-enum ndr_err_code ndr_push_string_array(struct ndr_push *ndr, int ndr_flags, const char **a);
+uint32_t ndr_size_string(int ret, const char * const* string, ndr_flags_type flags);
+enum ndr_err_code ndr_pull_string_array(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char ***_a);
+enum ndr_err_code ndr_push_string_array(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char **a);
 void ndr_print_string_array(struct ndr_print *ndr, const char *name, const char **a);
 size_t ndr_size_string_array(const char **a, uint32_t count, libndr_flags flags);
 uint32_t ndr_string_length(const void *_var, uint32_t element_size);
 enum ndr_err_code ndr_check_string_terminator(struct ndr_pull *ndr, uint32_t count, uint32_t element_size);
-enum ndr_err_code ndr_pull_charset(struct ndr_pull *ndr, int ndr_flags, const char **var, uint32_t length, uint8_t byte_mul, charset_t chset);
-enum ndr_err_code ndr_pull_charset_to_null(struct ndr_pull *ndr, int ndr_flags, const char **var, uint32_t length, uint8_t byte_mul, charset_t chset);
-enum ndr_err_code ndr_push_charset(struct ndr_push *ndr, int ndr_flags, const char *var, uint32_t length, uint8_t byte_mul, charset_t chset);
-enum ndr_err_code ndr_push_charset_to_null(struct ndr_push *ndr, int ndr_flags, const char *var, uint32_t length, uint8_t byte_mul, charset_t chset);
+enum ndr_err_code ndr_pull_charset(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **var, uint32_t length, uint8_t byte_mul, charset_t chset);
+enum ndr_err_code ndr_pull_charset_to_null(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **var, uint32_t length, uint8_t byte_mul, charset_t chset);
+enum ndr_err_code ndr_push_charset(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *var, uint32_t length, uint8_t byte_mul, charset_t chset);
+enum ndr_err_code ndr_push_charset_to_null(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *var, uint32_t length, uint8_t byte_mul, charset_t chset);
 
 /* GUIDs */
 bool GUID_equal(const struct GUID *u1, const struct GUID *u2);
@@ -853,31 +860,31 @@ struct GUID_txt_buf { char buf[39]; };
 _PUBLIC_ char* GUID_buf_string(const struct GUID *guid,
                               struct GUID_txt_buf *dst);
 
-_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint8(struct ndr_pull *ndr, int ndr_flags, uint8_t *v);
-_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint16(struct ndr_pull *ndr, int ndr_flags, uint16_t *v);
-_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint32(struct ndr_pull *ndr, int ndr_flags, uint32_t *v);
-_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint1632(struct ndr_pull *ndr, int ndr_flags, uint16_t *v);
-_PUBLIC_ enum ndr_err_code ndr_push_enum_uint8(struct ndr_push *ndr, int ndr_flags, uint8_t v);
-_PUBLIC_ enum ndr_err_code ndr_push_enum_uint16(struct ndr_push *ndr, int ndr_flags, uint16_t v);
-_PUBLIC_ enum ndr_err_code ndr_push_enum_uint32(struct ndr_push *ndr, int ndr_flags, uint32_t v);
-_PUBLIC_ enum ndr_err_code ndr_push_enum_uint1632(struct ndr_push *ndr, int ndr_flags, uint16_t v);
+_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint8(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint8_t *v);
+_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint16(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint16_t *v);
+_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint32(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *v);
+_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint1632(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint16_t *v);
+_PUBLIC_ enum ndr_err_code ndr_push_enum_uint8(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint8_t v);
+_PUBLIC_ enum ndr_err_code ndr_push_enum_uint16(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint16_t v);
+_PUBLIC_ enum ndr_err_code ndr_push_enum_uint32(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t v);
+_PUBLIC_ enum ndr_err_code ndr_push_enum_uint1632(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint16_t v);
 
 _PUBLIC_ void ndr_print_bool(struct ndr_print *ndr, const char *name, const bool b);
 
 _PUBLIC_ enum ndr_err_code ndr_push_timespec(struct ndr_push *ndr,
-                                            int ndr_flags,
+                                            ndr_flags_type ndr_flags,
                                             const struct timespec *t);
 _PUBLIC_ enum ndr_err_code ndr_pull_timespec(struct ndr_pull *ndr,
-                                            int ndr_flags,
+                                            ndr_flags_type ndr_flags,
                                             struct timespec *t);
 _PUBLIC_ void ndr_print_timespec(struct ndr_print *ndr, const char *name,
                                 const struct timespec *t);
 
 _PUBLIC_ enum ndr_err_code ndr_push_timeval(struct ndr_push *ndr,
-                                           int ndr_flags,
+                                           ndr_flags_type ndr_flags,
                                            const struct timeval *t);
 _PUBLIC_ enum ndr_err_code ndr_pull_timeval(struct ndr_pull *ndr,
-                                           int ndr_flags,
+                                           ndr_flags_type ndr_flags,
                                            struct timeval *t);
 _PUBLIC_ void ndr_print_timeval(struct ndr_print *ndr, const char *name,
                                const struct timeval *t);
index c7c8e0e359d09244bbf055543466c13dd601dac5..1478faa466f468e4b8e967ef7beca35a9ffdf549 100644 (file)
@@ -486,7 +486,7 @@ _PUBLIC_ void ndr_print_union_debug(ndr_print_fn_t fn, const char *name, uint32_
 /*
   a useful helper function for printing idl function calls via DEBUG()
 */
-_PUBLIC_ void ndr_print_function_debug(ndr_print_function_t fn, const char *name, int flags, void *ptr)
+_PUBLIC_ void ndr_print_function_debug(ndr_print_function_t fn, const char *name, ndr_flags_type flags, void *ptr)
 {
        struct ndr_print *ndr;
 
@@ -562,7 +562,7 @@ failed:
 */
 _PUBLIC_ char *ndr_print_function_string(TALLOC_CTX *mem_ctx,
                                ndr_print_function_t fn, const char *name,
-                               int flags, void *ptr)
+                               ndr_flags_type flags, void *ptr)
 {
        struct ndr_print *ndr;
        char *ret = NULL;
@@ -1207,7 +1207,7 @@ _PUBLIC_ enum ndr_err_code ndr_check_steal_array_length(struct ndr_pull *ndr, co
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_pipe_chunk_trailer(struct ndr_push *ndr, int ndr_flags, uint32_t count)
+_PUBLIC_ enum ndr_err_code ndr_push_pipe_chunk_trailer(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t count)
 {
        if (ndr->flags & LIBNDR_FLAG_NDR64) {
                int64_t tmp = 0 - (int64_t)count;
@@ -1219,7 +1219,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_pipe_chunk_trailer(struct ndr_push *ndr, int
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_check_pipe_chunk_trailer(struct ndr_pull *ndr, int ndr_flags, uint32_t count)
+_PUBLIC_ enum ndr_err_code ndr_check_pipe_chunk_trailer(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t count)
 {
        if (ndr->flags & LIBNDR_FLAG_NDR64) {
                int64_t tmp = 0 - (int64_t)count;
index 5252d800523bd72eb97f6ac69dcabb0af1913842..0600586ed164ba9f9dc49a20a81ed3179caef0ce 100644 (file)
@@ -31,12 +31,12 @@ _PUBLIC_ void ndr_print_cli_credentials(struct ndr_print *ndr, const char *name,
 /*
   cli_credentials does not have a network representation, just pull/push a NULL pointer
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_cli_credentials(struct ndr_pull *ndr, int ndr_flags, struct cli_credentials *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_cli_credentials(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct cli_credentials *v)
 {
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_cli_credentials(struct ndr_push *ndr, int ndr_flags, struct cli_credentials *v)
+_PUBLIC_ enum ndr_err_code ndr_push_cli_credentials(struct ndr_push *ndr, ndr_flags_type ndr_flags, struct cli_credentials *v)
 {
        return ndr_push_pointer(ndr, ndr_flags, NULL);
 }
index 57f653551f552e9cc83f2841b121f7d64d0e4282..9cc4ec25c4aada0b9286a4647c806c96108c75a8 100644 (file)
@@ -26,7 +26,7 @@
 #include "librpc/gen_ndr/ndr_auth.h"
 
 struct cli_credentials;
-_PUBLIC_ enum ndr_err_code ndr_pull_cli_credentials(struct ndr_pull *ndr, int ndr_flags, struct cli_credentials *v);
-_PUBLIC_ enum ndr_err_code ndr_push_cli_credentials(struct ndr_push *ndr, int ndr_flags, struct cli_credentials *v);
+_PUBLIC_ enum ndr_err_code ndr_pull_cli_credentials(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct cli_credentials *v);
+_PUBLIC_ enum ndr_err_code ndr_push_cli_credentials(struct ndr_push *ndr, ndr_flags_type ndr_flags, struct cli_credentials *v);
 
 _PUBLIC_ void ndr_print_cli_credentials(struct ndr_print *ndr, const char *name, struct cli_credentials *v);
index 635c9fa370023a154a4ee6c2069ec5054404cc02..9ce1abb23f361024e01365303c31866cfd4e4df5 100644 (file)
@@ -49,7 +49,7 @@ static uint32_t backupkeyguid_to_uint(const struct GUID *guid)
        return BACKUPKEY_INVALID_GUID_INTEGER;
 }
 
-_PUBLIC_ void ndr_print_bkrp_BackupKey(struct ndr_print *ndr, const char *name, int flags, const struct bkrp_BackupKey *r)
+_PUBLIC_ void ndr_print_bkrp_BackupKey(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct bkrp_BackupKey *r)
 {
        ndr_print_struct(ndr, name, "bkrp_BackupKey");
        if (r == NULL) { ndr_print_null(ndr); return; }
@@ -123,7 +123,7 @@ _PUBLIC_ void ndr_print_bkrp_BackupKey(struct ndr_print *ndr, const char *name,
  * purely in PIDL as the padding is sized so that the whole access_check_v3
  * struct size is a multiple of 8 (as specified in 2.2.2.3 of ms-bkrp.pdf)
  */
-_PUBLIC_ enum ndr_err_code ndr_push_bkrp_access_check_v2(struct ndr_push *ndr, int ndr_flags, const struct bkrp_access_check_v2 *r)
+_PUBLIC_ enum ndr_err_code ndr_push_bkrp_access_check_v2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct bkrp_access_check_v2 *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                size_t ofs;
@@ -148,7 +148,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_bkrp_access_check_v2(struct ndr_push *ndr, i
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_bkrp_access_check_v2(struct ndr_pull *ndr, int ndr_flags, struct bkrp_access_check_v2 *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_bkrp_access_check_v2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct bkrp_access_check_v2 *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                size_t ofs;
@@ -174,7 +174,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_bkrp_access_check_v2(struct ndr_pull *ndr, i
  * purely in PIDL as the padding is sized so that the whole access_check_v3
  * struct size is a multiple of 16 (as specified in 2.2.2.4 of ms-bkrp.pdf)
  */
-_PUBLIC_ enum ndr_err_code ndr_push_bkrp_access_check_v3(struct ndr_push *ndr, int ndr_flags, const struct bkrp_access_check_v3 *r)
+_PUBLIC_ enum ndr_err_code ndr_push_bkrp_access_check_v3(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct bkrp_access_check_v3 *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                size_t ofs;
@@ -199,7 +199,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_bkrp_access_check_v3(struct ndr_push *ndr, i
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_bkrp_access_check_v3(struct ndr_pull *ndr, int ndr_flags, struct bkrp_access_check_v3 *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_bkrp_access_check_v3(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct bkrp_access_check_v3 *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                size_t ofs;
index 4e82f6296adc86ac9c71faf64831df442d39bec9..20386d2fe15288a9aaee54b9d9563f23e873639e 100644 (file)
@@ -19,5 +19,5 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
 
-_PUBLIC_ enum ndr_err_code ndr_push_bkrp_access_check_v2(struct ndr_push *ndr, int ndr_flags, const struct bkrp_access_check_v2 *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_bkrp_access_check_v2(struct ndr_pull *ndr, int ndr_flags, struct bkrp_access_check_v2 *r);
+_PUBLIC_ enum ndr_err_code ndr_push_bkrp_access_check_v2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct bkrp_access_check_v2 *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_bkrp_access_check_v2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct bkrp_access_check_v2 *r);
index a88d7710f19aa5b04b6152de33e1c787a11b7efe..eae0fd062cb05c15e2c6b1450cc3b23d3f81b572 100644 (file)
@@ -104,7 +104,7 @@ _PUBLIC_ void ndr_check_padding(struct ndr_pull *ndr, size_t n)
 /*
   parse a int8_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_int8(struct ndr_pull *ndr, int ndr_flags, int8_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_int8(struct ndr_pull *ndr, ndr_flags_type ndr_flags, int8_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_NEED_BYTES(ndr, 1);
@@ -116,7 +116,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_int8(struct ndr_pull *ndr, int ndr_flags, in
 /*
   parse a uint8_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_uint8(struct ndr_pull *ndr, int ndr_flags, uint8_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_uint8(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint8_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_NEED_BYTES(ndr, 1);
@@ -128,7 +128,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_uint8(struct ndr_pull *ndr, int ndr_flags, u
 /*
   parse a int16_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_int16(struct ndr_pull *ndr, int ndr_flags, int16_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_int16(struct ndr_pull *ndr, ndr_flags_type ndr_flags, int16_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_ALIGN(ndr, 2);
@@ -141,7 +141,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_int16(struct ndr_pull *ndr, int ndr_flags, i
 /*
   parse a uint16_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_uint16(struct ndr_pull *ndr, int ndr_flags, uint16_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_uint16(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint16_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_ALIGN(ndr, 2);
@@ -154,7 +154,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_uint16(struct ndr_pull *ndr, int ndr_flags,
 /*
   parse a uint1632_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_uint1632(struct ndr_pull *ndr, int ndr_flags, uint16_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_uint1632(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint16_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        if (unlikely(ndr->flags & LIBNDR_FLAG_NDR64)) {
@@ -173,7 +173,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_uint1632(struct ndr_pull *ndr, int ndr_flags
 /*
   parse a int32_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_int32(struct ndr_pull *ndr, int ndr_flags, int32_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_int32(struct ndr_pull *ndr, ndr_flags_type ndr_flags, int32_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_ALIGN(ndr, 4);
@@ -186,7 +186,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_int32(struct ndr_pull *ndr, int ndr_flags, i
 /*
   parse a uint32_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_uint32(struct ndr_pull *ndr, int ndr_flags, uint32_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_uint32(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_ALIGN(ndr, 4);
@@ -199,7 +199,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_uint32(struct ndr_pull *ndr, int ndr_flags,
 /*
   parse a arch dependent uint32/uint64
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_uint3264(struct ndr_pull *ndr, int ndr_flags, uint32_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_uint3264(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *v)
 {
        uint64_t v64 = 0;
        enum ndr_err_code err;
@@ -224,7 +224,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_uint3264(struct ndr_pull *ndr, int ndr_flags
 /*
   parse a double
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_double(struct ndr_pull *ndr, int ndr_flags, double *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_double(struct ndr_pull *ndr, ndr_flags_type ndr_flags, double *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_ALIGN(ndr, 8);
@@ -273,7 +273,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_ref_ptr(struct ndr_pull *ndr, uint32_t *v)
 /*
   parse a udlong
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_udlong(struct ndr_pull *ndr, int ndr_flags, uint64_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_udlong(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint64_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_ALIGN(ndr, 4);
@@ -287,7 +287,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_udlong(struct ndr_pull *ndr, int ndr_flags,
 /*
   parse a udlongr
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_udlongr(struct ndr_pull *ndr, int ndr_flags, uint64_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_udlongr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint64_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_ALIGN(ndr, 4);
@@ -301,7 +301,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_udlongr(struct ndr_pull *ndr, int ndr_flags,
 /*
   parse a dlong
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_dlong(struct ndr_pull *ndr, int ndr_flags, int64_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_dlong(struct ndr_pull *ndr, ndr_flags_type ndr_flags, int64_t *v)
 {
        return ndr_pull_udlong(ndr, ndr_flags, (uint64_t *)v);
 }
@@ -309,7 +309,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_dlong(struct ndr_pull *ndr, int ndr_flags, i
 /*
   parse a hyper
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_hyper(struct ndr_pull *ndr, int ndr_flags, uint64_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_hyper(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint64_t *v)
 {
        NDR_PULL_ALIGN(ndr, 8);
        if (NDR_BE(ndr)) {
@@ -321,7 +321,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_hyper(struct ndr_pull *ndr, int ndr_flags, u
 /*
   parse an int64
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_int64(struct ndr_pull *ndr, int ndr_flags, int64_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_int64(struct ndr_pull *ndr, ndr_flags_type ndr_flags, int64_t *v)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PULL_ALIGN(ndr, 8);
@@ -334,7 +334,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_int64(struct ndr_pull *ndr, int ndr_flags, i
 /*
   parse a pointer
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_pointer(struct ndr_pull *ndr, int ndr_flags, void* *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_pointer(struct ndr_pull *ndr, ndr_flags_type ndr_flags, void* *v)
 {
        uintptr_t h;
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
@@ -349,7 +349,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_pointer(struct ndr_pull *ndr, int ndr_flags,
 /*
   pull a NTSTATUS
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_NTSTATUS(struct ndr_pull *ndr, int ndr_flags, NTSTATUS *status)
+_PUBLIC_ enum ndr_err_code ndr_pull_NTSTATUS(struct ndr_pull *ndr, ndr_flags_type ndr_flags, NTSTATUS *status)
 {
        uint32_t v;
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
@@ -361,7 +361,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_NTSTATUS(struct ndr_pull *ndr, int ndr_flags
 /*
   push a NTSTATUS
 */
-_PUBLIC_ enum ndr_err_code ndr_push_NTSTATUS(struct ndr_push *ndr, int ndr_flags, NTSTATUS status)
+_PUBLIC_ enum ndr_err_code ndr_push_NTSTATUS(struct ndr_push *ndr, ndr_flags_type ndr_flags, NTSTATUS status)
 {
        return ndr_push_uint32(ndr, ndr_flags, NT_STATUS_V(status));
 }
@@ -374,7 +374,7 @@ _PUBLIC_ void ndr_print_NTSTATUS(struct ndr_print *ndr, const char *name, NTSTAT
 /*
   pull a WERROR
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_WERROR(struct ndr_pull *ndr, int ndr_flags, WERROR *status)
+_PUBLIC_ enum ndr_err_code ndr_pull_WERROR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, WERROR *status)
 {
        uint32_t v;
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
@@ -386,7 +386,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_WERROR(struct ndr_pull *ndr, int ndr_flags,
 /*
   pull a HRESULT
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_HRESULT(struct ndr_pull *ndr, int ndr_flags, HRESULT *status)
+_PUBLIC_ enum ndr_err_code ndr_pull_HRESULT(struct ndr_pull *ndr, ndr_flags_type ndr_flags, HRESULT *status)
 {
        uint32_t v;
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
@@ -398,7 +398,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_HRESULT(struct ndr_pull *ndr, int ndr_flags,
 /*
   parse a uint8_t enum
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint8(struct ndr_pull *ndr, int ndr_flags, uint8_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint8(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint8_t *v)
 {
        return ndr_pull_uint8(ndr, ndr_flags, v);
 }
@@ -406,7 +406,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_enum_uint8(struct ndr_pull *ndr, int ndr_fla
 /*
   parse a uint16_t enum
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint16(struct ndr_pull *ndr, int ndr_flags, uint16_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint16(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint16_t *v)
 {
        return ndr_pull_uint16(ndr, ndr_flags, v);
 }
@@ -414,7 +414,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_enum_uint16(struct ndr_pull *ndr, int ndr_fl
 /*
   parse a uint1632_t enum (uint32_t on NDR64)
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint1632(struct ndr_pull *ndr, int ndr_flags, uint16_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint1632(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint16_t *v)
 {
        if (unlikely(ndr->flags & LIBNDR_FLAG_NDR64)) {
                uint32_t v32;
@@ -432,7 +432,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_enum_uint1632(struct ndr_pull *ndr, int ndr_
 /*
   parse a uint32_t enum
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint32(struct ndr_pull *ndr, int ndr_flags, uint32_t *v)
+_PUBLIC_ enum ndr_err_code ndr_pull_enum_uint32(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *v)
 {
        return ndr_pull_uint32(ndr, ndr_flags, v);
 }
@@ -440,7 +440,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_enum_uint32(struct ndr_pull *ndr, int ndr_fl
 /*
   push a uint8_t enum
 */
-_PUBLIC_ enum ndr_err_code ndr_push_enum_uint8(struct ndr_push *ndr, int ndr_flags, uint8_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_enum_uint8(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint8_t v)
 {
        return ndr_push_uint8(ndr, ndr_flags, v);
 }
@@ -448,7 +448,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_enum_uint8(struct ndr_push *ndr, int ndr_fla
 /*
   push a uint16_t enum
 */
-_PUBLIC_ enum ndr_err_code ndr_push_enum_uint16(struct ndr_push *ndr, int ndr_flags, uint16_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_enum_uint16(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint16_t v)
 {
        return ndr_push_uint16(ndr, ndr_flags, v);
 }
@@ -456,7 +456,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_enum_uint16(struct ndr_push *ndr, int ndr_fl
 /*
   push a uint32_t enum
 */
-_PUBLIC_ enum ndr_err_code ndr_push_enum_uint32(struct ndr_push *ndr, int ndr_flags, uint32_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_enum_uint32(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t v)
 {
        return ndr_push_uint32(ndr, ndr_flags, v);
 }
@@ -464,7 +464,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_enum_uint32(struct ndr_push *ndr, int ndr_fl
 /*
   push a uint1632_t enum
 */
-_PUBLIC_ enum ndr_err_code ndr_push_enum_uint1632(struct ndr_push *ndr, int ndr_flags, uint16_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_enum_uint1632(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint16_t v)
 {
        if (unlikely(ndr->flags & LIBNDR_FLAG_NDR64)) {
                return ndr_push_uint32(ndr, ndr_flags, v);
@@ -475,7 +475,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_enum_uint1632(struct ndr_push *ndr, int ndr_
 /*
   push a WERROR
 */
-_PUBLIC_ enum ndr_err_code ndr_push_WERROR(struct ndr_push *ndr, int ndr_flags, WERROR status)
+_PUBLIC_ enum ndr_err_code ndr_push_WERROR(struct ndr_push *ndr, ndr_flags_type ndr_flags, WERROR status)
 {
        return ndr_push_uint32(ndr, NDR_SCALARS, W_ERROR_V(status));
 }
@@ -488,7 +488,7 @@ _PUBLIC_ void ndr_print_WERROR(struct ndr_print *ndr, const char *name, WERROR r
 /*
   push a HRESULT
 */
-_PUBLIC_ enum ndr_err_code ndr_push_HRESULT(struct ndr_push *ndr, int ndr_flags, HRESULT status)
+_PUBLIC_ enum ndr_err_code ndr_push_HRESULT(struct ndr_push *ndr, ndr_flags_type ndr_flags, HRESULT status)
 {
        return ndr_push_uint32(ndr, NDR_SCALARS, HRES_ERROR_V(status));
 }
@@ -513,7 +513,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_bytes(struct ndr_pull *ndr, uint8_t *data, u
 /*
   pull an array of uint8
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_array_uint8(struct ndr_pull *ndr, int ndr_flags, uint8_t *data, uint32_t n)
+_PUBLIC_ enum ndr_err_code ndr_pull_array_uint8(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint8_t *data, uint32_t n)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        if (!(ndr_flags & NDR_SCALARS)) {
@@ -525,7 +525,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_array_uint8(struct ndr_pull *ndr, int ndr_fl
 /*
   push a int8_t
 */
-_PUBLIC_ enum ndr_err_code ndr_push_int8(struct ndr_push *ndr, int ndr_flags, int8_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_int8(struct ndr_push *ndr, ndr_flags_type ndr_flags, int8_t v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_NEED_BYTES(ndr, 1);
@@ -537,7 +537,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_int8(struct ndr_push *ndr, int ndr_flags, in
 /*
   push a uint8_t
 */
-_PUBLIC_ enum ndr_err_code ndr_push_uint8(struct ndr_push *ndr, int ndr_flags, uint8_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_uint8(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint8_t v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_NEED_BYTES(ndr, 1);
@@ -549,7 +549,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_uint8(struct ndr_push *ndr, int ndr_flags, u
 /*
   push a int16_t
 */
-_PUBLIC_ enum ndr_err_code ndr_push_int16(struct ndr_push *ndr, int ndr_flags, int16_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_int16(struct ndr_push *ndr, ndr_flags_type ndr_flags, int16_t v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_ALIGN(ndr, 2);
@@ -562,7 +562,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_int16(struct ndr_push *ndr, int ndr_flags, i
 /*
   push a uint16_t
 */
-_PUBLIC_ enum ndr_err_code ndr_push_uint16(struct ndr_push *ndr, int ndr_flags, uint16_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_uint16(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint16_t v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_ALIGN(ndr, 2);
@@ -575,7 +575,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_uint16(struct ndr_push *ndr, int ndr_flags,
 /*
   push a uint1632
 */
-_PUBLIC_ enum ndr_err_code ndr_push_uint1632(struct ndr_push *ndr, int ndr_flags, uint16_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_uint1632(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint16_t v)
 {
        if (unlikely(ndr->flags & LIBNDR_FLAG_NDR64)) {
                return ndr_push_uint32(ndr, ndr_flags, v);
@@ -586,7 +586,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_uint1632(struct ndr_push *ndr, int ndr_flags
 /*
   push a int32_t
 */
-_PUBLIC_ enum ndr_err_code ndr_push_int32(struct ndr_push *ndr, int ndr_flags, int32_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_int32(struct ndr_push *ndr, ndr_flags_type ndr_flags, int32_t v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_ALIGN(ndr, 4);
@@ -599,7 +599,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_int32(struct ndr_push *ndr, int ndr_flags, i
 /*
   push a uint32_t
 */
-_PUBLIC_ enum ndr_err_code ndr_push_uint32(struct ndr_push *ndr, int ndr_flags, uint32_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_uint32(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_ALIGN(ndr, 4);
@@ -612,7 +612,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_uint32(struct ndr_push *ndr, int ndr_flags,
 /*
   push a uint3264
 */
-_PUBLIC_ enum ndr_err_code ndr_push_uint3264(struct ndr_push *ndr, int ndr_flags, uint32_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_uint3264(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t v)
 {
        if (unlikely(ndr->flags & LIBNDR_FLAG_NDR64)) {
                return ndr_push_hyper(ndr, ndr_flags, v);
@@ -623,7 +623,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_uint3264(struct ndr_push *ndr, int ndr_flags
 /*
   push a udlong
 */
-_PUBLIC_ enum ndr_err_code ndr_push_udlong(struct ndr_push *ndr, int ndr_flags, uint64_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_udlong(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint64_t v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_ALIGN(ndr, 4);
@@ -637,7 +637,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_udlong(struct ndr_push *ndr, int ndr_flags,
 /*
   push a udlongr
 */
-_PUBLIC_ enum ndr_err_code ndr_push_udlongr(struct ndr_push *ndr, int ndr_flags, uint64_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_udlongr(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint64_t v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_ALIGN(ndr, 4);
@@ -651,7 +651,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_udlongr(struct ndr_push *ndr, int ndr_flags,
 /*
   push a dlong
 */
-_PUBLIC_ enum ndr_err_code ndr_push_dlong(struct ndr_push *ndr, int ndr_flags, int64_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_dlong(struct ndr_push *ndr, ndr_flags_type ndr_flags, int64_t v)
 {
        return ndr_push_udlong(ndr, NDR_SCALARS, (uint64_t)v);
 }
@@ -659,7 +659,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_dlong(struct ndr_push *ndr, int ndr_flags, i
 /*
   push a hyper
 */
-_PUBLIC_ enum ndr_err_code ndr_push_hyper(struct ndr_push *ndr, int ndr_flags, uint64_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_hyper(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint64_t v)
 {
        NDR_PUSH_ALIGN(ndr, 8);
        if (NDR_BE(ndr)) {
@@ -671,7 +671,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_hyper(struct ndr_push *ndr, int ndr_flags, u
 /*
   push an int64
 */
-_PUBLIC_ enum ndr_err_code ndr_push_int64(struct ndr_push *ndr, int ndr_flags, int64_t v)
+_PUBLIC_ enum ndr_err_code ndr_push_int64(struct ndr_push *ndr, ndr_flags_type ndr_flags, int64_t v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_ALIGN(ndr, 8);
@@ -684,7 +684,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_int64(struct ndr_push *ndr, int ndr_flags, i
 /*
   push a double
 */
-_PUBLIC_ enum ndr_err_code ndr_push_double(struct ndr_push *ndr, int ndr_flags, double v)
+_PUBLIC_ enum ndr_err_code ndr_push_double(struct ndr_push *ndr, ndr_flags_type ndr_flags, double v)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_PUSH_ALIGN(ndr, 8);
@@ -697,7 +697,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_double(struct ndr_push *ndr, int ndr_flags,
 /*
   push a pointer
 */
-_PUBLIC_ enum ndr_err_code ndr_push_pointer(struct ndr_push *ndr, int ndr_flags, void* v)
+_PUBLIC_ enum ndr_err_code ndr_push_pointer(struct ndr_push *ndr, ndr_flags_type ndr_flags, void* v)
 {
        uintptr_t h = (intptr_t)v;
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
@@ -815,7 +815,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_zero(struct ndr_push *ndr, uint32_t n)
 /*
   push an array of uint8
 */
-_PUBLIC_ enum ndr_err_code ndr_push_array_uint8(struct ndr_push *ndr, int ndr_flags, const uint8_t *data, uint32_t n)
+_PUBLIC_ enum ndr_err_code ndr_push_array_uint8(struct ndr_push *ndr, ndr_flags_type ndr_flags, const uint8_t *data, uint32_t n)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        if (!(ndr_flags & NDR_SCALARS)) {
@@ -874,7 +874,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_ref_ptr(struct ndr_push *ndr)
 /*
   push a NTTIME
 */
-_PUBLIC_ enum ndr_err_code ndr_push_NTTIME(struct ndr_push *ndr, int ndr_flags, NTTIME t)
+_PUBLIC_ enum ndr_err_code ndr_push_NTTIME(struct ndr_push *ndr, ndr_flags_type ndr_flags, NTTIME t)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_CHECK(ndr_push_udlong(ndr, ndr_flags, t));
@@ -884,7 +884,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_NTTIME(struct ndr_push *ndr, int ndr_flags,
 /*
   pull a NTTIME
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_NTTIME(struct ndr_pull *ndr, int ndr_flags, NTTIME *t)
+_PUBLIC_ enum ndr_err_code ndr_pull_NTTIME(struct ndr_pull *ndr, ndr_flags_type ndr_flags, NTTIME *t)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_CHECK(ndr_pull_udlong(ndr, ndr_flags, t));
@@ -894,7 +894,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_NTTIME(struct ndr_pull *ndr, int ndr_flags,
 /*
   push a NTTIME_1sec
 */
-_PUBLIC_ enum ndr_err_code ndr_push_NTTIME_1sec(struct ndr_push *ndr, int ndr_flags, NTTIME t)
+_PUBLIC_ enum ndr_err_code ndr_push_NTTIME_1sec(struct ndr_push *ndr, ndr_flags_type ndr_flags, NTTIME t)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        t /= 10000000;
@@ -905,7 +905,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_NTTIME_1sec(struct ndr_push *ndr, int ndr_fl
 /*
   pull a NTTIME_1sec
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_NTTIME_1sec(struct ndr_pull *ndr, int ndr_flags, NTTIME *t)
+_PUBLIC_ enum ndr_err_code ndr_pull_NTTIME_1sec(struct ndr_pull *ndr, ndr_flags_type ndr_flags, NTTIME *t)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_CHECK(ndr_pull_hyper(ndr, ndr_flags, t));
@@ -916,7 +916,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_NTTIME_1sec(struct ndr_pull *ndr, int ndr_fl
 /*
   pull a NTTIME_hyper
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_NTTIME_hyper(struct ndr_pull *ndr, int ndr_flags, NTTIME *t)
+_PUBLIC_ enum ndr_err_code ndr_pull_NTTIME_hyper(struct ndr_pull *ndr, ndr_flags_type ndr_flags, NTTIME *t)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        NDR_CHECK(ndr_pull_hyper(ndr, ndr_flags, t));
@@ -926,7 +926,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_NTTIME_hyper(struct ndr_pull *ndr, int ndr_f
 /*
   push a NTTIME_hyper
 */
-_PUBLIC_ enum ndr_err_code ndr_push_NTTIME_hyper(struct ndr_push *ndr, int ndr_flags, NTTIME t)
+_PUBLIC_ enum ndr_err_code ndr_push_NTTIME_hyper(struct ndr_push *ndr, ndr_flags_type ndr_flags, NTTIME t)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        NDR_CHECK(ndr_push_hyper(ndr, ndr_flags, t));
@@ -936,7 +936,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_NTTIME_hyper(struct ndr_push *ndr, int ndr_f
 /*
   push a time_t
 */
-_PUBLIC_ enum ndr_err_code ndr_push_time_t(struct ndr_push *ndr, int ndr_flags, time_t t)
+_PUBLIC_ enum ndr_err_code ndr_push_time_t(struct ndr_push *ndr, ndr_flags_type ndr_flags, time_t t)
 {
        return ndr_push_uint32(ndr, ndr_flags, t);
 }
@@ -944,7 +944,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_time_t(struct ndr_push *ndr, int ndr_flags,
 /*
   pull a time_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_time_t(struct ndr_pull *ndr, int ndr_flags, time_t *t)
+_PUBLIC_ enum ndr_err_code ndr_pull_time_t(struct ndr_pull *ndr, ndr_flags_type ndr_flags, time_t *t)
 {
        uint32_t tt;
        NDR_CHECK(ndr_pull_uint32(ndr, ndr_flags, &tt));
@@ -956,7 +956,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_time_t(struct ndr_pull *ndr, int ndr_flags,
 /*
   push a uid_t
 */
-_PUBLIC_ enum ndr_err_code ndr_push_uid_t(struct ndr_push *ndr, int ndr_flags, uid_t u)
+_PUBLIC_ enum ndr_err_code ndr_push_uid_t(struct ndr_push *ndr, ndr_flags_type ndr_flags, uid_t u)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        return ndr_push_hyper(ndr, NDR_SCALARS, (uint64_t)u);
@@ -965,7 +965,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_uid_t(struct ndr_push *ndr, int ndr_flags, u
 /*
   pull a uid_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_uid_t(struct ndr_pull *ndr, int ndr_flags, uid_t *u)
+_PUBLIC_ enum ndr_err_code ndr_pull_uid_t(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uid_t *u)
 {
        uint64_t uu = 0;
        NDR_CHECK(ndr_pull_hyper(ndr, ndr_flags, &uu));
@@ -982,7 +982,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_uid_t(struct ndr_pull *ndr, int ndr_flags, u
 /*
   push a gid_t
 */
-_PUBLIC_ enum ndr_err_code ndr_push_gid_t(struct ndr_push *ndr, int ndr_flags, gid_t g)
+_PUBLIC_ enum ndr_err_code ndr_push_gid_t(struct ndr_push *ndr, ndr_flags_type ndr_flags, gid_t g)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        return ndr_push_hyper(ndr, NDR_SCALARS, (uint64_t)g);
@@ -991,7 +991,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_gid_t(struct ndr_push *ndr, int ndr_flags, g
 /*
   pull a gid_t
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_gid_t(struct ndr_pull *ndr, int ndr_flags, gid_t *g)
+_PUBLIC_ enum ndr_err_code ndr_pull_gid_t(struct ndr_pull *ndr, ndr_flags_type ndr_flags, gid_t *g)
 {
        uint64_t gg = 0;
        NDR_CHECK(ndr_pull_hyper(ndr, ndr_flags, &gg));
@@ -1008,7 +1008,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_gid_t(struct ndr_pull *ndr, int ndr_flags, g
 /*
   pull a ipv4address
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_ipv4address(struct ndr_pull *ndr, int ndr_flags, const char **address)
+_PUBLIC_ enum ndr_err_code ndr_pull_ipv4address(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **address)
 {
        uint32_t addr;
        struct in_addr in;
@@ -1022,7 +1022,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_ipv4address(struct ndr_pull *ndr, int ndr_fl
 /*
   push a ipv4address
 */
-_PUBLIC_ enum ndr_err_code ndr_push_ipv4address(struct ndr_push *ndr, int ndr_flags, const char *address)
+_PUBLIC_ enum ndr_err_code ndr_push_ipv4address(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *address)
 {
        uint32_t addr;
        if (!is_ipaddress_v4(address)) {
@@ -1049,7 +1049,7 @@ _PUBLIC_ void ndr_print_ipv4address(struct ndr_print *ndr, const char *name,
 */
 #define IPV6_BYTES 16
 #define IPV6_ADDR_STR_LEN 39
-_PUBLIC_ enum ndr_err_code ndr_pull_ipv6address(struct ndr_pull *ndr, int ndr_flags, const char **address)
+_PUBLIC_ enum ndr_err_code ndr_pull_ipv6address(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **address)
 {
        uint8_t addr[IPV6_BYTES];
        char *addr_str = talloc_strdup(ndr->current_mem_ctx, "");
@@ -1073,7 +1073,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_ipv6address(struct ndr_pull *ndr, int ndr_fl
 /*
   push a ipv6address
 */
-_PUBLIC_ enum ndr_err_code ndr_push_ipv6address(struct ndr_push *ndr, int ndr_flags, const char *address)
+_PUBLIC_ enum ndr_err_code ndr_push_ipv6address(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *address)
 {
 #ifdef AF_INET6
        uint8_t addr[IPV6_BYTES];
@@ -1402,7 +1402,7 @@ _PUBLIC_ void ndr_print_DATA_BLOB(struct ndr_print *ndr, const char *name, DATA_
  * 3) Otherwise, push a uint3264 length _and_ a corresponding byte array to the
  *    ndr buffer.
  */
-_PUBLIC_ enum ndr_err_code ndr_push_DATA_BLOB(struct ndr_push *ndr, int ndr_flags, DATA_BLOB blob)
+_PUBLIC_ enum ndr_err_code ndr_push_DATA_BLOB(struct ndr_push *ndr, ndr_flags_type ndr_flags, DATA_BLOB blob)
 {
        if (ndr->flags & LIBNDR_FLAG_REMAINING) {
                /* nothing to do */
@@ -1433,7 +1433,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_DATA_BLOB(struct ndr_push *ndr, int ndr_flag
  * 3) Otherwise, pull a uint3264 length _and_ a corresponding byte array from the
  *    ndr buffer.
  */
-_PUBLIC_ enum ndr_err_code ndr_pull_DATA_BLOB(struct ndr_pull *ndr, int ndr_flags, DATA_BLOB *blob)
+_PUBLIC_ enum ndr_err_code ndr_pull_DATA_BLOB(struct ndr_pull *ndr, ndr_flags_type ndr_flags, DATA_BLOB *blob)
 {
        uint32_t length = 0;
 
@@ -1459,7 +1459,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_DATA_BLOB(struct ndr_pull *ndr, int ndr_flag
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ uint32_t ndr_size_DATA_BLOB(int ret, const DATA_BLOB *data, int flags)
+_PUBLIC_ uint32_t ndr_size_DATA_BLOB(int ret, const DATA_BLOB *data, ndr_flags_type flags)
 {
        if (!data) return ret;
        return ret + data->length;
@@ -1521,7 +1521,7 @@ _PUBLIC_ int ndr_map_error2errno(enum ndr_err_code ndr_err)
 }
 
 _PUBLIC_ enum ndr_err_code ndr_push_timespec(struct ndr_push *ndr,
-                                            int ndr_flags,
+                                            ndr_flags_type ndr_flags,
                                             const struct timespec *t)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
@@ -1531,7 +1531,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_timespec(struct ndr_push *ndr,
 }
 
 _PUBLIC_ enum ndr_err_code ndr_pull_timespec(struct ndr_pull *ndr,
-                                            int ndr_flags,
+                                            ndr_flags_type ndr_flags,
                                             struct timespec *t)
 {
        uint64_t secs = 0;
@@ -1553,7 +1553,7 @@ _PUBLIC_ void ndr_print_timespec(struct ndr_print *ndr, const char *name,
 }
 
 _PUBLIC_ enum ndr_err_code ndr_push_timeval(struct ndr_push *ndr,
-                                           int ndr_flags,
+                                           ndr_flags_type ndr_flags,
                                            const struct timeval *t)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
@@ -1563,7 +1563,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_timeval(struct ndr_push *ndr,
 }
 
 _PUBLIC_ enum ndr_err_code ndr_pull_timeval(struct ndr_pull *ndr,
-                                           int ndr_flags,
+                                           ndr_flags_type ndr_flags,
                                            struct timeval *t)
 {
        uint64_t secs = 0;
index d374c3035b9191aea07f4684b9a31b784ab6a23c..34c183939d5d996fd34ef4fe36a73c6662afe818 100644 (file)
@@ -23,7 +23,7 @@
 #include "librpc/gen_ndr/ndr_bkupblobs.h"
 
 
-_PUBLIC_ enum ndr_err_code ndr_push_bkup_NTBackupFile(struct ndr_push *ndr, int ndr_flags, const struct bkup_NTBackupFile *r)
+_PUBLIC_ enum ndr_err_code ndr_push_bkup_NTBackupFile(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct bkup_NTBackupFile *r)
 {
        uint32_t cntr_streams_0;
        {
@@ -53,7 +53,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_bkup_NTBackupFile(struct ndr_push *ndr, int
        } \
 } while (0)
 
-_PUBLIC_ enum ndr_err_code ndr_pull_bkup_NTBackupFile(struct ndr_pull *ndr, int ndr_flags, struct bkup_NTBackupFile *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_bkup_NTBackupFile(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct bkup_NTBackupFile *r)
 {
        uint32_t cntr_streams_0;
        {
index a0c85bf90abd8d0bbcde8ea5f4058f25f24bcb68..ae3353bc25c61ef7d32d6d4962dce40c21fb527a 100644 (file)
@@ -248,7 +248,7 @@ static enum ndr_err_code ndr_push_folder_cfdata(struct ndr_push *ndr,
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_cab_file(struct ndr_push *ndr, int ndr_flags, const struct cab_file *r)
+_PUBLIC_ enum ndr_err_code ndr_push_cab_file(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct cab_file *r)
 {
        uint32_t cntr_cffolders_0;
        uint32_t cntr_cffiles_0;
@@ -381,7 +381,7 @@ static enum ndr_err_code ndr_pull_folder_cfdata(struct ndr_pull *ndr,
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_cab_file(struct ndr_pull *ndr, int ndr_flags, struct cab_file *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_cab_file(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct cab_file *r)
 {
        uint32_t size_cffolders_0 = 0;
        uint32_t cntr_cffolders_0;
index 0b2563aba144b4021e10c8bacb401c5c90703572..b368bfaa8189e73a5fd715bc9a55a65ee6307d34 100644 (file)
@@ -24,7 +24,7 @@
 #include "librpc/gen_ndr/ndr_dcerpc.h"
 #include "librpc/gen_ndr/ndr_misc.h"
 
-_PUBLIC_ enum ndr_err_code ndr_push_ncacn_packet(struct ndr_push *ndr, int ndr_flags, const struct ncacn_packet *r)
+_PUBLIC_ enum ndr_err_code ndr_push_ncacn_packet(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ncacn_packet *r)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        if (ndr_flags & NDR_SCALARS) {
@@ -52,7 +52,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_ncacn_packet(struct ndr_push *ndr, int ndr_f
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_ncacn_packet(struct ndr_pull *ndr, int ndr_flags, struct ncacn_packet *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_ncacn_packet(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ncacn_packet *r)
 {
        uint32_t size_drep_0 = 0;
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
@@ -112,7 +112,7 @@ _PUBLIC_ void ndr_print_ncacn_packet(struct ndr_print *ndr, const char *name, co
  *
  * That's why we ignore the 80 char per line limit.
  */
-enum ndr_err_code ndr_pull_dcerpc_bind_nak(struct ndr_pull *ndr, int ndr_flags, struct dcerpc_bind_nak *r)
+enum ndr_err_code ndr_pull_dcerpc_bind_nak(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dcerpc_bind_nak *r)
 {
        uint32_t size_versions_0 = 0;
        uint32_t cntr_versions_0;
@@ -157,14 +157,14 @@ enum ndr_err_code ndr_pull_dcerpc_bind_nak(struct ndr_pull *ndr, int ndr_flags,
 
 const uint8_t DCERPC_SEC_VT_MAGIC[] = {0x8a,0xe3,0x13,0x71,0x02,0xf4,0x36,0x71};
 
-_PUBLIC_ enum ndr_err_code ndr_push_dcerpc_sec_vt_count(struct ndr_push *ndr, int ndr_flags, const struct dcerpc_sec_vt_count *r)
+_PUBLIC_ enum ndr_err_code ndr_push_dcerpc_sec_vt_count(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct dcerpc_sec_vt_count *r)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        /* nothing */
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_dcerpc_sec_vt_count(struct ndr_pull *ndr, int ndr_flags, struct dcerpc_sec_vt_count *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_dcerpc_sec_vt_count(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dcerpc_sec_vt_count *r)
 {
        uint32_t _saved_ofs = ndr->offset;
 
index 18c2c075acc552740d9c92f8e6d907d79e7aea84..9cc54c1a9727e40feabcf0dc2171bdc6c58cc891 100644 (file)
@@ -112,7 +112,7 @@ static enum ndr_err_code ndr_pull_component(struct ndr_pull *ndr,
   pull a dns_string from the wire
 */
 _PUBLIC_ enum ndr_err_code ndr_pull_dns_string(struct ndr_pull *ndr,
-                                              int ndr_flags,
+                                              ndr_flags_type ndr_flags,
                                               const char **s)
 {
        uint32_t offset = ndr->offset;
@@ -157,7 +157,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_dns_string(struct ndr_pull *ndr,
   push a dns string to the wire
 */
 _PUBLIC_ enum ndr_err_code ndr_push_dns_string(struct ndr_push *ndr,
-                                              int ndr_flags,
+                                              ndr_flags_type ndr_flags,
                                               const char *s)
 {
        return ndr_push_dns_string_list(ndr,
@@ -167,7 +167,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_dns_string(struct ndr_push *ndr,
                                        false);
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_dns_txt_record(struct ndr_pull *ndr, int ndr_flags, struct dns_txt_record *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_dns_txt_record(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dns_txt_record *r)
 {
        NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
        if (ndr_flags & NDR_SCALARS) {
@@ -191,7 +191,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_dns_txt_record(struct ndr_pull *ndr, int ndr
 }
 
 _PUBLIC_ enum ndr_err_code ndr_push_dns_res_rec(struct ndr_push *ndr,
-                                               int ndr_flags,
+                                               ndr_flags_type ndr_flags,
                                                const struct dns_res_rec *r)
 {
        libndr_flags _flags_save_STRUCT = ndr->flags;
@@ -266,7 +266,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_dns_res_rec(struct ndr_push *ndr,
 }
 
 _PUBLIC_ enum ndr_err_code ndr_pull_dns_res_rec(struct ndr_pull *ndr,
-                                               int ndr_flags,
+                                               ndr_flags_type ndr_flags,
                                                struct dns_res_rec *r)
 {
        libndr_flags _flags_save_STRUCT = ndr->flags;
index 16bf11ba87f72f1ea16d012d416bb0cc58874331..15617eb203157cfa1332f79a573626ae0ad2de95 100644 (file)
@@ -27,14 +27,14 @@ void ndr_print_dns_string(struct ndr_print *ndr,
                          const char *name,
                          const char *s);
 enum ndr_err_code ndr_pull_dns_string(struct ndr_pull *ndr,
-                                     int ndr_flags,
+                                     ndr_flags_type ndr_flags,
                                      const char **s);
 enum ndr_err_code ndr_push_dns_string(struct ndr_push *ndr,
-                                     int ndr_flags,
+                                     ndr_flags_type ndr_flags,
                                      const char *s);
 enum ndr_err_code ndr_push_dns_res_rec(struct ndr_push *ndr,
-                                      int ndr_flags,
+                                      ndr_flags_type ndr_flags,
                                       const struct dns_res_rec *r);
 enum ndr_err_code ndr_pull_dns_res_rec(struct ndr_pull *ndr,
-                                      int ndr_flags,
+                                      ndr_flags_type ndr_flags,
                                       struct dns_res_rec *r);
index e9c43681feb1603b2fe8105836f4ce45911d83a2..a2e04640d52cd818418a7ae03333af3db46fb5aa 100644 (file)
@@ -8,7 +8,7 @@
 */
 enum ndr_err_code ndr_push_dns_string_list(struct ndr_push *ndr,
                                           struct ndr_token_list *string_list,
-                                          int ndr_flags,
+                                          ndr_flags_type ndr_flags,
                                           const char *s,
                                           bool is_nbt)
 {
index 71a65433bbb1d8fbdf180694eef3b70d86061ebd..b07496f7458bafe133cb4af4bc143bc7a444f554 100644 (file)
@@ -1,6 +1,6 @@
 
 enum ndr_err_code ndr_push_dns_string_list(struct ndr_push *ndr,
                                           struct ndr_token_list *string_list,
-                                          int ndr_flags,
+                                          ndr_flags_type ndr_flags,
                                           const char *s,
                                           bool is_nbt);
index ac469c312d5b3ebcb0a38f476a9296f9673e5782..b4cad86392d5a5dc6209bf8c892138b3c0054438 100644 (file)
@@ -34,7 +34,7 @@ _PUBLIC_ void ndr_print_dnsp_name(struct ndr_print *ndr, const char *name,
 /*
   pull a dnsp_name
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_dnsp_name(struct ndr_pull *ndr, int ndr_flags, const char **name)
+_PUBLIC_ enum ndr_err_code ndr_pull_dnsp_name(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **name)
 {
        uint8_t len, count, termination;
        int i;
@@ -96,7 +96,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_dnsp_name(struct ndr_pull *ndr, int ndr_flag
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_dnsp_name(struct ndr_push *ndr, int ndr_flags, const char *name)
+enum ndr_err_code ndr_push_dnsp_name(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *name)
 {
        int count, total_len, i;
 
@@ -151,7 +151,7 @@ _PUBLIC_ void ndr_print_dnsp_string(struct ndr_print *ndr, const char *name,
 /*
   pull a dnsp_string
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_dnsp_string(struct ndr_pull *ndr, int ndr_flags, const char **string)
+_PUBLIC_ enum ndr_err_code ndr_pull_dnsp_string(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **string)
 {
        uint8_t len;
        char *ret;
@@ -169,7 +169,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_dnsp_string(struct ndr_pull *ndr, int ndr_fl
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_dnsp_string(struct ndr_push *ndr, int ndr_flags, const char *string)
+enum ndr_err_code ndr_push_dnsp_string(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *string)
 {
        int total_len;
        total_len = strlen(string);
@@ -206,7 +206,7 @@ _PUBLIC_ void ndr_print_dnsp_string_list(struct ndr_print *ndr, const char *name
 /*
  * pull a dnsp_string_list
  */
-_PUBLIC_ enum ndr_err_code ndr_pull_dnsp_string_list(struct ndr_pull *ndr, int ndr_flags, struct dnsp_string_list *list)
+_PUBLIC_ enum ndr_err_code ndr_pull_dnsp_string_list(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dnsp_string_list *list)
 {
        list->count = 0;
        list->str = talloc_array(ndr->current_mem_ctx, const char *,
@@ -228,7 +228,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_dnsp_string_list(struct ndr_pull *ndr, int n
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_dnsp_string_list(struct ndr_push *ndr, int ndr_flags, const struct dnsp_string_list *list)
+enum ndr_err_code ndr_push_dnsp_string_list(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct dnsp_string_list *list)
 {
        uint8_t i;
 
index 0d566336c352bc1af0dfbbcdd9c96d38f9deee37..1f68f2935297da626a0d33423556d374f724c1d2 100644 (file)
 
 void ndr_print_dnsp_name(struct ndr_print *ndr, const char *name,
                                  const char *dns_name);
-enum ndr_err_code ndr_pull_dnsp_name(struct ndr_pull *ndr, int ndr_flags, const char **name);
-enum ndr_err_code ndr_push_dnsp_name(struct ndr_push *ndr, int ndr_flags, const char *name);
+enum ndr_err_code ndr_pull_dnsp_name(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **name);
+enum ndr_err_code ndr_push_dnsp_name(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *name);
 void ndr_print_dnsp_string(struct ndr_print *ndr, const char *name,
                                  const char *dns_string);
-enum ndr_err_code ndr_pull_dnsp_string(struct ndr_pull *ndr, int ndr_flags, const char **string);
-enum ndr_err_code ndr_push_dnsp_string(struct ndr_push *ndr, int ndr_flags, const char *string);
+enum ndr_err_code ndr_pull_dnsp_string(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **string);
+enum ndr_err_code ndr_push_dnsp_string(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *string);
 
 enum ndr_err_code ndr_dnsp_string_list_copy(TALLOC_CTX *mem_ctx,
                                            const struct dnsp_string_list *src,
index 3201f0428a31280455bcd37d9babeecede59fdd5..814a3665108c0e3301a2bf6932f84fedca4eaa6e 100644 (file)
@@ -28,7 +28,7 @@
  */
 
 enum ndr_err_code ndr_pull_DNS_RPC_RECORDS_ARRAY(struct ndr_pull *ndr,
-               int ndr_flags, struct DNS_RPC_RECORDS_ARRAY *rec)
+               ndr_flags_type ndr_flags, struct DNS_RPC_RECORDS_ARRAY *rec)
 {
        rec->count = 0;
        rec->rec = talloc_array(ndr->current_mem_ctx, struct DNS_RPC_RECORDS, rec->count);
@@ -50,7 +50,7 @@ enum ndr_err_code ndr_pull_DNS_RPC_RECORDS_ARRAY(struct ndr_pull *ndr,
 }
 
 enum ndr_err_code ndr_push_DNS_RPC_RECORDS_ARRAY(struct ndr_push *ndr,
-               int ndr_flags, const struct DNS_RPC_RECORDS_ARRAY *rec)
+               ndr_flags_type ndr_flags, const struct DNS_RPC_RECORDS_ARRAY *rec)
 {
        int i;
 
@@ -67,7 +67,7 @@ enum ndr_err_code ndr_push_DNS_RPC_RECORDS_ARRAY(struct ndr_push *ndr,
  */
 
 enum ndr_err_code ndr_pull_DNS_RPC_RECORD_STRING(struct ndr_pull *ndr,
-               int ndr_flags, struct DNS_RPC_RECORD_STRING *rec)
+               ndr_flags_type ndr_flags, struct DNS_RPC_RECORD_STRING *rec)
 {
        rec->count = 0;
        rec->str = talloc_array(ndr->current_mem_ctx, struct DNS_RPC_NAME, rec->count);
@@ -88,7 +88,7 @@ enum ndr_err_code ndr_pull_DNS_RPC_RECORD_STRING(struct ndr_pull *ndr,
 }
 
 enum ndr_err_code ndr_push_DNS_RPC_RECORD_STRING(struct ndr_push *ndr,
-               int ndr_flags, const struct DNS_RPC_RECORD_STRING *rec)
+               ndr_flags_type ndr_flags, const struct DNS_RPC_RECORD_STRING *rec)
 {
        int i;
 
index 68eb863a73bed61198a508fa533e338dec26f517..04eb2205d28a18a7e273288d3d52969362b1c1d1 100644 (file)
@@ -20,6 +20,6 @@
 */
 
 enum ndr_err_code ndr_pull_DNS_RPC_RECORDS_ARRAY(struct ndr_pull *ndr,
-               int ndr_flags, struct DNS_RPC_RECORDS_ARRAY *rec);
+               ndr_flags_type ndr_flags, struct DNS_RPC_RECORDS_ARRAY *rec);
 enum ndr_err_code ndr_push_DNS_RPC_RECORDS_ARRAY(struct ndr_push *ndr,
-               int ndr_flags, const struct DNS_RPC_RECORDS_ARRAY *rec);
+               ndr_flags_type ndr_flags, const struct DNS_RPC_RECORDS_ARRAY *rec);
index 943275bea378d86534b8ab2298d14c083b089300..b6eea1757d06acfb62362f014d19f9afe61e6692 100644 (file)
@@ -24,7 +24,7 @@
 #include "librpc/gen_ndr/ndr_drsblobs.h"
 #include "../lib/util/asn1.h"
 
-_PUBLIC_ enum ndr_err_code ndr_push_AuthenticationInformationArray(struct ndr_push *ndr, int ndr_flags, const struct AuthenticationInformationArray *r)
+_PUBLIC_ enum ndr_err_code ndr_push_AuthenticationInformationArray(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct AuthenticationInformationArray *r)
 {
        uint32_t cntr_array_0;
        if (ndr_flags & NDR_SCALARS) {
@@ -39,7 +39,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_AuthenticationInformationArray(struct ndr_pu
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_AuthenticationInformationArray(struct ndr_pull *ndr, int ndr_flags, struct AuthenticationInformationArray *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_AuthenticationInformationArray(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct AuthenticationInformationArray *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                r->count = 0;
@@ -58,7 +58,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_AuthenticationInformationArray(struct ndr_pu
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_trustAuthInOutBlob(struct ndr_push *ndr, int ndr_flags, const struct trustAuthInOutBlob *r)
+_PUBLIC_ enum ndr_err_code ndr_push_trustAuthInOutBlob(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct trustAuthInOutBlob *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                NDR_CHECK(ndr_push_align(ndr, 4));
@@ -90,7 +90,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_trustAuthInOutBlob(struct ndr_push *ndr, int
 }
 
 
-_PUBLIC_ enum ndr_err_code ndr_pull_trustDomainPasswords(struct ndr_pull *ndr, int ndr_flags, struct trustDomainPasswords *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_trustDomainPasswords(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct trustDomainPasswords *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                uint32_t offset;
@@ -150,7 +150,7 @@ _PUBLIC_ void ndr_print_drsuapi_MSPrefixMap_Entry(struct ndr_print *ndr, const c
        }
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_supplementalCredentialsSubBlob(struct ndr_push *ndr, int ndr_flags, const struct supplementalCredentialsSubBlob *r)
+_PUBLIC_ enum ndr_err_code ndr_push_supplementalCredentialsSubBlob(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct supplementalCredentialsSubBlob *r)
 {
        uint32_t cntr_packages_0;
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
@@ -175,7 +175,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_supplementalCredentialsSubBlob(struct ndr_pu
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_supplementalCredentialsSubBlob(struct ndr_pull *ndr, int ndr_flags, struct supplementalCredentialsSubBlob *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_supplementalCredentialsSubBlob(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct supplementalCredentialsSubBlob *r)
 {
        uint32_t size_prefix_0 = 0;
        uint32_t size_packages_0 = 0;
index eb7993c3142c477d69421054149adc2c31b25118..d3108088a228c1de9965de37d22dfc4909965b6e 100644 (file)
@@ -19,5 +19,5 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
 
-_PUBLIC_ enum ndr_err_code ndr_pull_trustDomainPasswords(struct ndr_pull *ndr, int ndr_flags, struct trustDomainPasswords *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_trustDomainPasswords(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct trustDomainPasswords *r);
 _PUBLIC_ void ndr_print_drsuapi_MSPrefixMap_Entry(struct ndr_print *ndr, const char *name, const struct drsuapi_MSPrefixMap_Entry *r);
index 4b4dec127a6f50ea46b59a973150b38bde0ac9d9..63d1d74b6e8c7813a800e463bd3c383a021dd2e8 100644 (file)
@@ -205,7 +205,7 @@ _PUBLIC_ void ndr_print_drsuapi_DsReplicaAttribute(struct ndr_print *ndr,
        ndr->depth--;
 }
 
-enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesMSZIPCtr1(struct ndr_push *ndr, int ndr_flags, const struct drsuapi_DsGetNCChangesMSZIPCtr1 *r)
+enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesMSZIPCtr1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct drsuapi_DsGetNCChangesMSZIPCtr1 *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                uint32_t decompressed_length = 0;
@@ -250,7 +250,7 @@ enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesMSZIPCtr1(struct ndr_push *ndr,
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesMSZIPCtr6(struct ndr_push *ndr, int ndr_flags, const struct drsuapi_DsGetNCChangesMSZIPCtr6 *r)
+enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesMSZIPCtr6(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct drsuapi_DsGetNCChangesMSZIPCtr6 *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                uint32_t decompressed_length = 0;
@@ -295,7 +295,7 @@ enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesMSZIPCtr6(struct ndr_push *ndr,
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesWIN2K3_LZ77_DIRECT2Ctr1(struct ndr_push *ndr, int ndr_flags, const struct drsuapi_DsGetNCChangesWIN2K3_LZ77_DIRECT2Ctr1 *r)
+enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesWIN2K3_LZ77_DIRECT2Ctr1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct drsuapi_DsGetNCChangesWIN2K3_LZ77_DIRECT2Ctr1 *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                uint32_t decompressed_length = 0;
@@ -340,7 +340,7 @@ enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesWIN2K3_LZ77_DIRECT2Ctr1(struct
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesWIN2K3_LZ77_DIRECT2Ctr6(struct ndr_push *ndr, int ndr_flags, const struct drsuapi_DsGetNCChangesWIN2K3_LZ77_DIRECT2Ctr6 *r)
+enum ndr_err_code ndr_push_drsuapi_DsGetNCChangesWIN2K3_LZ77_DIRECT2Ctr6(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct drsuapi_DsGetNCChangesWIN2K3_LZ77_DIRECT2Ctr6 *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                uint32_t decompressed_length = 0;
@@ -425,7 +425,7 @@ _PUBLIC_ void ndr_print_drsuapi_DsAddEntry_AttrErrListItem_V1(struct ndr_print *
        }
 }
 
-enum ndr_err_code ndr_push_drsuapi_DsBindInfo(struct ndr_push *ndr, int ndr_flags, const union drsuapi_DsBindInfo *r)
+enum ndr_err_code ndr_push_drsuapi_DsBindInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union drsuapi_DsBindInfo *r)
 {
        libndr_flags _flags_save = ndr->flags;
        ndr->flags = ndr->flags & ~LIBNDR_FLAG_NDR64;
@@ -486,7 +486,7 @@ enum ndr_err_code ndr_push_drsuapi_DsBindInfo(struct ndr_push *ndr, int ndr_flag
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_drsuapi_DsBindInfo(struct ndr_pull *ndr, int ndr_flags, union drsuapi_DsBindInfo *r)
+enum ndr_err_code ndr_pull_drsuapi_DsBindInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union drsuapi_DsBindInfo *r)
 {
        libndr_flags _flags_save = ndr->flags;
        ndr->flags = ndr->flags & ~LIBNDR_FLAG_NDR64;
index f7dae910347d112d345dc9ad0ead070b5191afdc..78c00ede50716d3bdd015359ea10b317ff004976 100644 (file)
@@ -23,7 +23,7 @@
 #include "librpc/gen_ndr/ndr_frsrpc.h"
 
 enum ndr_err_code ndr_push_frsrpc_CommPktChunkCtr(struct ndr_push *ndr,
-                                       int ndr_flags,
+                                       ndr_flags_type ndr_flags,
                                        const struct frsrpc_CommPktChunkCtr *r)
 {
        uint32_t cntr_chunks_0;
@@ -54,7 +54,7 @@ enum ndr_err_code ndr_push_frsrpc_CommPktChunkCtr(struct ndr_push *ndr,
 } while (0)
 
 enum ndr_err_code ndr_pull_frsrpc_CommPktChunkCtr(struct ndr_pull *ndr,
-                                       int ndr_flags,
+                                       ndr_flags_type ndr_flags,
                                        struct frsrpc_CommPktChunkCtr *r)
 {
        uint32_t cntr_chunks_0;
index b9d2ea98c4929891bb3a5bc4af96bf88b04df15b..afdfd661cce9d8efe8a63e2d1ca2f4ea5bd0d52c 100644 (file)
 #define _LIBRPC_NDR_NDR_FRSRPC_H
 
 enum ndr_err_code ndr_push_frsrpc_CommPktChunkCtr(struct ndr_push *ndr,
-                                       int ndr_flags,
+                                       ndr_flags_type ndr_flags,
                                        const struct frsrpc_CommPktChunkCtr *r);
 enum ndr_err_code ndr_pull_frsrpc_CommPktChunkCtr(struct ndr_pull *ndr,
-                                       int ndr_flags,
+                                       ndr_flags_type ndr_flags,
                                        struct frsrpc_CommPktChunkCtr *r);
 size_t ndr_size_frsrpc_CommPktChunkCtr(const struct frsrpc_CommPktChunkCtr *r,
                                       libndr_flags flags);
index 3ea8d9e9e3a63913fd10be4bb724f40a76347007..60eacd33c98cb0e0d16aea86b8b16f0418fec112 100644 (file)
@@ -36,7 +36,7 @@ size_t _ndr_size_PAC_INFO(const union PAC_INFO *r, uint32_t level, libndr_flags
        }
 }
 
-enum ndr_err_code ndr_push_PAC_BUFFER(struct ndr_push *ndr, int ndr_flags, const struct PAC_BUFFER *r)
+enum ndr_err_code ndr_push_PAC_BUFFER(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct PAC_BUFFER *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                NDR_CHECK(ndr_push_align(ndr, 4));
@@ -75,7 +75,7 @@ enum ndr_err_code ndr_push_PAC_BUFFER(struct ndr_push *ndr, int ndr_flags, const
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_PAC_BUFFER(struct ndr_pull *ndr, int ndr_flags, struct PAC_BUFFER *r)
+enum ndr_err_code ndr_pull_PAC_BUFFER(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct PAC_BUFFER *r)
 {
        uint32_t _ptr_info;
        TALLOC_CTX *_mem_save_info_0;
index a9cc1411fe4896adb3d5f74708ed1efb0ae20166..eb186810785e3d8a2d5510e18f7d575704eb3112 100644 (file)
@@ -98,7 +98,7 @@ static enum ndr_err_code ndr_pull_component(struct ndr_pull *ndr,
 /**
   pull a nbt_string from the wire
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_nbt_string(struct ndr_pull *ndr, int ndr_flags, const char **s)
+_PUBLIC_ enum ndr_err_code ndr_pull_nbt_string(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **s)
 {
        uint32_t offset = ndr->offset;
        uint32_t max_offset = offset;
@@ -141,7 +141,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_nbt_string(struct ndr_pull *ndr, int ndr_fla
 /**
   push a nbt string to the wire
 */
-_PUBLIC_ enum ndr_err_code ndr_push_nbt_string(struct ndr_push *ndr, int ndr_flags, const char *s)
+_PUBLIC_ enum ndr_err_code ndr_push_nbt_string(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *s)
 {
        return ndr_push_dns_string_list(ndr,
                                        &ndr->dns_string_list,
@@ -152,7 +152,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_nbt_string(struct ndr_push *ndr, int ndr_fla
 
 
 /* Manually modified to handle the dom_sid being optional based on if it is present or all zero */
-enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_REQUEST(struct ndr_push *ndr, int ndr_flags, const struct NETLOGON_SAM_LOGON_REQUEST *r)
+enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_REQUEST(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct NETLOGON_SAM_LOGON_REQUEST *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                NDR_CHECK(ndr_push_align(ndr, 4));
@@ -197,7 +197,7 @@ enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_REQUEST(struct ndr_push *ndr, int
 }
 
 /* Manually modified to handle the dom_sid being optional based on if it is present (size is non-zero) or not */
-enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_REQUEST(struct ndr_pull *ndr, int ndr_flags, struct NETLOGON_SAM_LOGON_REQUEST *r)
+enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_REQUEST(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct NETLOGON_SAM_LOGON_REQUEST *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                NDR_CHECK(ndr_pull_align(ndr, 4));
@@ -244,7 +244,7 @@ enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_REQUEST(struct ndr_pull *ndr, int
 }
 
 /* Manually modified to only push some parts of the structure if certain flags are set */
-enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_push *ndr, int ndr_flags, const struct NETLOGON_SAM_LOGON_RESPONSE_EX *r)
+enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct NETLOGON_SAM_LOGON_RESPONSE_EX *r)
 {
        {
                libndr_flags _flags_save_STRUCT = ndr->flags;
@@ -288,7 +288,7 @@ enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_
 }
 
 /* Manually modified to only pull some parts of the structure if certain flags provided */
-enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_pull *ndr, int ndr_flags, struct NETLOGON_SAM_LOGON_RESPONSE_EX *r,
+enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct NETLOGON_SAM_LOGON_RESPONSE_EX *r,
                                                                     uint32_t nt_version_flags)
 {
        {
@@ -336,7 +336,7 @@ enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_netlogon_samlogon_response(struct ndr_push *ndr, int ndr_flags, const struct netlogon_samlogon_response *r)
+_PUBLIC_ enum ndr_err_code ndr_push_netlogon_samlogon_response(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct netlogon_samlogon_response *r)
 {
        if (r->ntver == NETLOGON_NT_VERSION_1) {
                NDR_CHECK(ndr_push_NETLOGON_SAM_LOGON_RESPONSE_NT40(
@@ -354,7 +354,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_netlogon_samlogon_response(struct ndr_push *
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_netlogon_samlogon_response(struct ndr_pull *ndr, int ndr_flags, struct netlogon_samlogon_response *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_netlogon_samlogon_response(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct netlogon_samlogon_response *r)
 {
        if (ndr->data_size < 8) {
                return NDR_ERR_BUFSIZE;
index 7c06301d02bf97ceed765df6e75cb61edbb7aa53..c38422fff6b693eb6c9209b400bbc0a09cd1c966 100644 (file)
 
 NDR_SCALAR_PROTO(nbt_string, const char *)
 
-enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_REQUEST(struct ndr_push *ndr, int ndr_flags, const struct NETLOGON_SAM_LOGON_REQUEST *r);
-enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_REQUEST(struct ndr_pull *ndr, int ndr_flags, struct NETLOGON_SAM_LOGON_REQUEST *r);
-enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_push *ndr, int ndr_flags, const struct NETLOGON_SAM_LOGON_RESPONSE_EX *r);
-enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_pull *ndr, int ndr_flags, struct NETLOGON_SAM_LOGON_RESPONSE_EX *r,
+enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_REQUEST(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct NETLOGON_SAM_LOGON_REQUEST *r);
+enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_REQUEST(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct NETLOGON_SAM_LOGON_REQUEST *r);
+enum ndr_err_code ndr_push_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct NETLOGON_SAM_LOGON_RESPONSE_EX *r);
+enum ndr_err_code ndr_pull_NETLOGON_SAM_LOGON_RESPONSE_EX_with_flags(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct NETLOGON_SAM_LOGON_RESPONSE_EX *r,
                                                                     uint32_t nt_version_flags);
-enum ndr_err_code ndr_push_netlogon_samlogon_response(struct ndr_push *ndr, int ndr_flags, const struct netlogon_samlogon_response *r);
-enum ndr_err_code ndr_pull_netlogon_samlogon_response(struct ndr_pull *ndr, int ndr_flags, struct netlogon_samlogon_response *r);
+enum ndr_err_code ndr_push_netlogon_samlogon_response(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct netlogon_samlogon_response *r);
+enum ndr_err_code ndr_pull_netlogon_samlogon_response(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct netlogon_samlogon_response *r);
 void ndr_print_netlogon_samlogon_response(struct ndr_print *ndr, const char *name, struct netlogon_samlogon_response *r);
 
 #endif /* _LIBRPC_NDR_NDR_NBT_H */
index f8084d50680c53cd89c0e010b73cc2945bbd181e..26b98f40be875d36f3ce906382db588d9da71a04 100644 (file)
@@ -32,7 +32,7 @@ void ndr_print_negoex_BYTE_VECTOR(struct ndr_print *ndr, const char *name, const
        ndr->depth--;
 }
 
-enum ndr_err_code ndr_push_negoex_BYTE_VECTOR(struct ndr_push *ndr, int ndr_flags, const struct negoex_BYTE_VECTOR *r)
+enum ndr_err_code ndr_push_negoex_BYTE_VECTOR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_BYTE_VECTOR *r)
 {
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
        if (ndr_flags & NDR_SCALARS) {
@@ -54,7 +54,7 @@ enum ndr_err_code ndr_push_negoex_BYTE_VECTOR(struct ndr_push *ndr, int ndr_flag
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_negoex_BYTE_VECTOR(struct ndr_pull *ndr, int ndr_flags, struct negoex_BYTE_VECTOR *r)
+enum ndr_err_code ndr_pull_negoex_BYTE_VECTOR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_BYTE_VECTOR *r)
 {
        uint32_t _ptr_data;
        uint32_t size_data_1 = 0;
@@ -106,7 +106,7 @@ enum ndr_err_code ndr_pull_negoex_BYTE_VECTOR(struct ndr_pull *ndr, int ndr_flag
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_negoex_AUTH_SCHEME_VECTOR(struct ndr_push *ndr, int ndr_flags, const struct negoex_AUTH_SCHEME_VECTOR *r)
+enum ndr_err_code ndr_push_negoex_AUTH_SCHEME_VECTOR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_AUTH_SCHEME_VECTOR *r)
 {
        uint32_t cntr_array_1;
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
@@ -131,7 +131,7 @@ enum ndr_err_code ndr_push_negoex_AUTH_SCHEME_VECTOR(struct ndr_push *ndr, int n
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_negoex_AUTH_SCHEME_VECTOR(struct ndr_pull *ndr, int ndr_flags, struct negoex_AUTH_SCHEME_VECTOR *r)
+enum ndr_err_code ndr_pull_negoex_AUTH_SCHEME_VECTOR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_AUTH_SCHEME_VECTOR *r)
 {
        uint32_t _ptr_array;
        uint32_t size_array_1 = 0;
@@ -186,7 +186,7 @@ enum ndr_err_code ndr_pull_negoex_AUTH_SCHEME_VECTOR(struct ndr_pull *ndr, int n
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_negoex_EXTENSION_VECTOR(struct ndr_push *ndr, int ndr_flags, const struct negoex_EXTENSION_VECTOR *r)
+enum ndr_err_code ndr_push_negoex_EXTENSION_VECTOR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_EXTENSION_VECTOR *r)
 {
        uint32_t cntr_array_1;
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
@@ -214,7 +214,7 @@ enum ndr_err_code ndr_push_negoex_EXTENSION_VECTOR(struct ndr_push *ndr, int ndr
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_negoex_EXTENSION_VECTOR(struct ndr_pull *ndr, int ndr_flags, struct negoex_EXTENSION_VECTOR *r)
+enum ndr_err_code ndr_pull_negoex_EXTENSION_VECTOR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_EXTENSION_VECTOR *r)
 {
        uint32_t _ptr_array;
        uint32_t size_array_1 = 0;
@@ -272,7 +272,7 @@ enum ndr_err_code ndr_pull_negoex_EXTENSION_VECTOR(struct ndr_pull *ndr, int ndr
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_negoex_ALERT_VECTOR(struct ndr_push *ndr, int ndr_flags, const struct negoex_ALERT_VECTOR *r)
+enum ndr_err_code ndr_push_negoex_ALERT_VECTOR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_ALERT_VECTOR *r)
 {
        uint32_t cntr_array_1;
        NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
@@ -300,7 +300,7 @@ enum ndr_err_code ndr_push_negoex_ALERT_VECTOR(struct ndr_push *ndr, int ndr_fla
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_negoex_ALERT_VECTOR(struct ndr_pull *ndr, int ndr_flags, struct negoex_ALERT_VECTOR *r)
+enum ndr_err_code ndr_pull_negoex_ALERT_VECTOR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_ALERT_VECTOR *r)
 {
        uint32_t _ptr_array;
        uint32_t size_array_1 = 0;
@@ -404,7 +404,7 @@ size_t ndr_negoex_MESSAGE_header_length(const struct negoex_MESSAGE *r)
        return size;
 }
 
-enum ndr_err_code ndr_pull_negoex_MESSAGE(struct ndr_pull *ndr, int ndr_flags, struct negoex_MESSAGE *r)
+enum ndr_err_code ndr_pull_negoex_MESSAGE(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_MESSAGE *r)
 {
        uint32_t _save_relative_base_offset = ndr_pull_get_relative_base_offset(ndr);
        uint32_t size_signature_0 = 0;
@@ -448,7 +448,7 @@ enum ndr_err_code ndr_pull_negoex_MESSAGE(struct ndr_pull *ndr, int ndr_flags, s
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_negoex_MESSAGE_ARRAY(struct ndr_push *ndr, int ndr_flags, const struct negoex_MESSAGE_ARRAY *r)
+enum ndr_err_code ndr_push_negoex_MESSAGE_ARRAY(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_MESSAGE_ARRAY *r)
 {
        uint32_t cntr_messages_0;
        {
@@ -467,7 +467,7 @@ enum ndr_err_code ndr_push_negoex_MESSAGE_ARRAY(struct ndr_push *ndr, int ndr_fl
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_negoex_MESSAGE_ARRAY(struct ndr_pull *ndr, int ndr_flags, struct negoex_MESSAGE_ARRAY *r)
+enum ndr_err_code ndr_pull_negoex_MESSAGE_ARRAY(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_MESSAGE_ARRAY *r)
 {
        uint32_t size_messages_0 = 0;
        uint32_t cntr_messages_0;
index d3c39b27388413709dff5c5374d36e92abebd414..094275c4cd09b24bdb5cb2ff1779f8161f1e12ce 100644 (file)
 #include "librpc/gen_ndr/negoex.h"
 
 _PUBLIC_ void ndr_print_negoex_BYTE_VECTOR(struct ndr_print *ndr, const char *name, const struct negoex_BYTE_VECTOR *r);
-_PUBLIC_ enum ndr_err_code ndr_push_negoex_BYTE_VECTOR(struct ndr_push *ndr, int ndr_flags, const struct negoex_BYTE_VECTOR *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_negoex_BYTE_VECTOR(struct ndr_pull *ndr, int ndr_flags, struct negoex_BYTE_VECTOR *r);
-_PUBLIC_ enum ndr_err_code ndr_push_negoex_AUTH_SCHEME_VECTOR(struct ndr_push *ndr, int ndr_flags, const struct negoex_AUTH_SCHEME_VECTOR *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_negoex_AUTH_SCHEME_VECTOR(struct ndr_pull *ndr, int ndr_flags, struct negoex_AUTH_SCHEME_VECTOR *r);
-_PUBLIC_ enum ndr_err_code ndr_push_negoex_EXTENSION_VECTOR(struct ndr_push *ndr, int ndr_flags, const struct negoex_EXTENSION_VECTOR *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_negoex_EXTENSION_VECTOR(struct ndr_pull *ndr, int ndr_flags, struct negoex_EXTENSION_VECTOR *r);
-_PUBLIC_ enum ndr_err_code ndr_push_negoex_ALERT_VECTOR(struct ndr_push *ndr, int ndr_flags, const struct negoex_ALERT_VECTOR *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_negoex_ALERT_VECTOR(struct ndr_pull *ndr, int ndr_flags, struct negoex_ALERT_VECTOR *r);
+_PUBLIC_ enum ndr_err_code ndr_push_negoex_BYTE_VECTOR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_BYTE_VECTOR *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_negoex_BYTE_VECTOR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_BYTE_VECTOR *r);
+_PUBLIC_ enum ndr_err_code ndr_push_negoex_AUTH_SCHEME_VECTOR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_AUTH_SCHEME_VECTOR *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_negoex_AUTH_SCHEME_VECTOR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_AUTH_SCHEME_VECTOR *r);
+_PUBLIC_ enum ndr_err_code ndr_push_negoex_EXTENSION_VECTOR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_EXTENSION_VECTOR *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_negoex_EXTENSION_VECTOR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_EXTENSION_VECTOR *r);
+_PUBLIC_ enum ndr_err_code ndr_push_negoex_ALERT_VECTOR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_ALERT_VECTOR *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_negoex_ALERT_VECTOR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_ALERT_VECTOR *r);
 _PUBLIC_ size_t ndr_negoex_MESSAGE_header_length(const struct negoex_MESSAGE *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_negoex_MESSAGE(struct ndr_pull *ndr, int ndr_flags, struct negoex_MESSAGE *r);
-_PUBLIC_ enum ndr_err_code ndr_push_negoex_MESSAGE_ARRAY(struct ndr_push *ndr, int ndr_flags, const struct negoex_MESSAGE_ARRAY *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_negoex_MESSAGE_ARRAY(struct ndr_pull *ndr, int ndr_flags, struct negoex_MESSAGE_ARRAY *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_negoex_MESSAGE(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_MESSAGE *r);
+_PUBLIC_ enum ndr_err_code ndr_push_negoex_MESSAGE_ARRAY(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct negoex_MESSAGE_ARRAY *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_negoex_MESSAGE_ARRAY(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct negoex_MESSAGE_ARRAY *r);
index 411f3b9ba06365f7455fd6871a095da5b581aeba..56f0eab7d67fca2947744c642bba44683522ccec 100644 (file)
 #include "librpc/gen_ndr/ndr_misc.h"
 #include "librpc/gen_ndr/ndr_samr.h"
 
-_PUBLIC_ enum ndr_err_code ndr_push_netr_SamDatabaseID8Bit(struct ndr_push *ndr, int ndr_flags, enum netr_SamDatabaseID8Bit r)
+_PUBLIC_ enum ndr_err_code ndr_push_netr_SamDatabaseID8Bit(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum netr_SamDatabaseID8Bit r)
 {
        if (r > 0xff) return NDR_ERR_BUFSIZE;
        NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r));
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_netr_SamDatabaseID8Bit(struct ndr_pull *ndr, int ndr_flags, enum netr_SamDatabaseID8Bit *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_netr_SamDatabaseID8Bit(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum netr_SamDatabaseID8Bit *r)
 {
        uint8_t v;
        NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &v));
@@ -44,14 +44,14 @@ _PUBLIC_ void ndr_print_netr_SamDatabaseID8Bit(struct ndr_print *ndr, const char
        ndr_print_netr_SamDatabaseID(ndr, name, r);
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_netr_DeltaEnum8Bit(struct ndr_push *ndr, int ndr_flags, enum netr_DeltaEnum8Bit r)
+_PUBLIC_ enum ndr_err_code ndr_push_netr_DeltaEnum8Bit(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum netr_DeltaEnum8Bit r)
 {
        if (r > 0xff) return NDR_ERR_BUFSIZE;
        NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r));
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_netr_DeltaEnum8Bit(struct ndr_pull *ndr, int ndr_flags, enum netr_DeltaEnum8Bit *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_netr_DeltaEnum8Bit(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum netr_DeltaEnum8Bit *r)
 {
        uint8_t v;
        NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &v));
index 0e6bd6a410ace6046379949af833c202ca49ac32..66faddec6bbd1e640a4d6761bbe98fbc025978d5 100644 (file)
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
 
-_PUBLIC_ enum ndr_err_code ndr_push_netr_SamDatabaseID8Bit(struct ndr_push *ndr, int ndr_flags, enum netr_SamDatabaseID8Bit r);
-_PUBLIC_ enum ndr_err_code ndr_pull_netr_SamDatabaseID8Bit(struct ndr_pull *ndr, int ndr_flags, enum netr_SamDatabaseID8Bit *r);
+_PUBLIC_ enum ndr_err_code ndr_push_netr_SamDatabaseID8Bit(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum netr_SamDatabaseID8Bit r);
+_PUBLIC_ enum ndr_err_code ndr_pull_netr_SamDatabaseID8Bit(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum netr_SamDatabaseID8Bit *r);
 _PUBLIC_ void ndr_print_netr_SamDatabaseID8Bit(struct ndr_print *ndr, const char *name, enum netr_SamDatabaseID8Bit r);
 
-_PUBLIC_ enum ndr_err_code ndr_push_netr_DeltaEnum8Bit(struct ndr_push *ndr, int ndr_flags, enum netr_DeltaEnum8Bit r);
-_PUBLIC_ enum ndr_err_code ndr_pull_netr_DeltaEnum8Bit(struct ndr_pull *ndr, int ndr_flags, enum netr_DeltaEnum8Bit *r);
+_PUBLIC_ enum ndr_err_code ndr_push_netr_DeltaEnum8Bit(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum netr_DeltaEnum8Bit r);
+_PUBLIC_ enum ndr_err_code ndr_pull_netr_DeltaEnum8Bit(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum netr_DeltaEnum8Bit *r);
 _PUBLIC_ void ndr_print_netr_DeltaEnum8Bit(struct ndr_print *ndr, const char *name, enum netr_DeltaEnum8Bit r);
index 80f104c6341110361fba3fd79e70aadd66c73a00..723ae9c6e35e2b52035bc77101f2b8a7808ebfb6 100644 (file)
@@ -48,7 +48,7 @@ _PUBLIC_ libndr_flags ndr_ntlmssp_negotiated_string_flags(uint32_t negotiate_fla
        return flags;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_AV_PAIR_LIST(struct ndr_push *ndr, int ndr_flags, const struct AV_PAIR_LIST *r)
+_PUBLIC_ enum ndr_err_code ndr_push_AV_PAIR_LIST(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct AV_PAIR_LIST *r)
 {
        uint32_t cntr_pair_0;
        if (ndr_flags & NDR_SCALARS) {
@@ -65,7 +65,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_AV_PAIR_LIST(struct ndr_push *ndr, int ndr_f
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_AV_PAIR_LIST(struct ndr_pull *ndr, int ndr_flags, struct AV_PAIR_LIST *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_AV_PAIR_LIST(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct AV_PAIR_LIST *r)
 {
        uint32_t cntr_pair_0;
        TALLOC_CTX *_mem_save_pair_0;
index 5cca4046d34e046b915eea5e8d7a2d6b0ba70aa5..2326a08bb7d5e932bb793b277ea58c95c7e08450 100644 (file)
@@ -21,8 +21,8 @@
 
 _PUBLIC_ size_t ndr_ntlmssp_string_length(uint32_t negotiate_flags, const char *s);
 _PUBLIC_ libndr_flags ndr_ntlmssp_negotiated_string_flags(uint32_t negotiate_flags);
-_PUBLIC_ enum ndr_err_code ndr_push_AV_PAIR_LIST(struct ndr_push *ndr, int ndr_flags, const struct AV_PAIR_LIST *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_AV_PAIR_LIST(struct ndr_pull *ndr, int ndr_flags, struct AV_PAIR_LIST *r);
+_PUBLIC_ enum ndr_err_code ndr_push_AV_PAIR_LIST(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct AV_PAIR_LIST *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_AV_PAIR_LIST(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct AV_PAIR_LIST *r);
 _PUBLIC_ void ndr_print_ntlmssp_nt_response(TALLOC_CTX *mem_ctx,
                                            const DATA_BLOB *nt_response,
                                            bool ntlmv2);
index 928bed8e360b83671d5d8d22572f9468f8fa911d..22010ff212c80c2ee1654c657000ceb87481afd9 100644 (file)
@@ -37,7 +37,7 @@ _PUBLIC_ libndr_flags ndr_ntprinting_string_flags(libndr_flags string_flags)
        return flags;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_ntprinting_printer(struct ndr_pull *ndr, int ndr_flags, struct ntprinting_printer *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_ntprinting_printer(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ntprinting_printer *r)
 {
        uint32_t _ptr_devmode;
        TALLOC_CTX *_mem_save_devmode_0;
index 7c52ea7f20d8e1914001a76e3ab895e2e5eebd82..4b89707316cd7a5760fe0aba7a66ce8550f02338 100644 (file)
@@ -24,4 +24,4 @@
 
 _PUBLIC_ libndr_flags ndr_ntprinting_string_flags(libndr_flags string_flags);
 
-_PUBLIC_ enum ndr_err_code ndr_pull_ntprinting_printer(struct ndr_pull *ndr, int ndr_flags, struct ntprinting_printer *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_ntprinting_printer(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ntprinting_printer *r);
index 01ba885d94250a9c8805b8554228a5173eacee0c..80d9870e2605f3aa2cf6c973e534241acabb03f7 100644 (file)
@@ -23,7 +23,7 @@
 #include "includes.h"
 #include "librpc/gen_ndr/ndr_orpc.h"
 
-enum ndr_err_code ndr_pull_DUALSTRINGARRAY(struct ndr_pull *ndr, int ndr_flags, struct DUALSTRINGARRAY *ar)
+enum ndr_err_code ndr_pull_DUALSTRINGARRAY(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct DUALSTRINGARRAY *ar)
 {
        uint16_t num_entries, security_offset;
        uint16_t towerid;
@@ -77,7 +77,7 @@ enum ndr_err_code ndr_pull_DUALSTRINGARRAY(struct ndr_pull *ndr, int ndr_flags,
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_DUALSTRINGARRAY(struct ndr_push *ndr, int ndr_flags, const struct DUALSTRINGARRAY *ar)
+enum ndr_err_code ndr_push_DUALSTRINGARRAY(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct DUALSTRINGARRAY *ar)
 {
        return ndr_push_error(ndr, NDR_ERR_STRING, "ndr_push_DUALSTRINGARRAY not implemented");
 }
@@ -108,7 +108,7 @@ void ndr_print_DUALSTRINGARRAY(struct ndr_print *ndr, const char *name, const st
        ndr->depth--;
 }
 
-enum ndr_err_code ndr_pull_STRINGARRAY(struct ndr_pull *ndr, int ndr_flags, struct STRINGARRAY *ar)
+enum ndr_err_code ndr_pull_STRINGARRAY(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct STRINGARRAY *ar)
 {
        uint16_t towerid;
        uint32_t towernum = 0;
@@ -141,7 +141,7 @@ enum ndr_err_code ndr_pull_STRINGARRAY(struct ndr_pull *ndr, int ndr_flags, stru
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_STRINGARRAY(struct ndr_push *ndr, int ndr_flags, const struct STRINGARRAY *ar)
+enum ndr_err_code ndr_push_STRINGARRAY(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct STRINGARRAY *ar)
 {
        return ndr_push_error(ndr, NDR_ERR_STRING, "ndr_push_STRINGARRAY not implemented");
 }
index f8d178bcc0323fb6545d30e1a0155c0a94ea5901..8074e1ebfd7ef8c983b5ba94588e4349c0786c23 100644 (file)
@@ -22,7 +22,7 @@
 #include "includes.h"
 #include "librpc/gen_ndr/ndr_preg.h"
 
-_PUBLIC_ enum ndr_err_code ndr_push_preg_file(struct ndr_push *ndr, int ndr_flags, const struct preg_file *r)
+_PUBLIC_ enum ndr_err_code ndr_push_preg_file(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct preg_file *r)
 {
        uint32_t cntr_entries_0;
        {
@@ -43,7 +43,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_preg_file(struct ndr_push *ndr, int ndr_flag
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_preg_file(struct ndr_pull *ndr, int ndr_flags, struct preg_file *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_preg_file(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct preg_file *r)
 {
        {
                libndr_flags _flags_save_STRUCT = ndr->flags;
index d781e138be496e953168851679e2d702c73d1461..f634225f091b2eb69de6e7342548881b309eaf59 100644 (file)
@@ -19,5 +19,5 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
 
-_PUBLIC_ enum ndr_err_code ndr_push_preg_file(struct ndr_push *ndr, int ndr_flags, const struct preg_file *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_preg_file(struct ndr_pull *ndr, int ndr_flags, struct preg_file *r);
+_PUBLIC_ enum ndr_err_code ndr_push_preg_file(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct preg_file *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_preg_file(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct preg_file *r);
index 16e16f40c6a91f0d4519ec9bbed4b4bad37901eb..d74d31b28232927337ccfd2f494e764a0771df4d 100644 (file)
@@ -181,7 +181,7 @@ void ndr_print_dom_sid0(struct ndr_print *ndr, const char *name, const struct do
 /*
   parse a dom_sid2 - this is a dom_sid but with an extra copy of the num_auths field
 */
-enum ndr_err_code ndr_pull_dom_sid2(struct ndr_pull *ndr, int ndr_flags, struct dom_sid *sid)
+enum ndr_err_code ndr_pull_dom_sid2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dom_sid *sid)
 {
        uint32_t num_auths;
        if (!(ndr_flags & NDR_SCALARS)) {
@@ -200,7 +200,7 @@ enum ndr_err_code ndr_pull_dom_sid2(struct ndr_pull *ndr, int ndr_flags, struct
 /*
   parse a dom_sid2 - this is a dom_sid but with an extra copy of the num_auths field
 */
-enum ndr_err_code ndr_push_dom_sid2(struct ndr_push *ndr, int ndr_flags, const struct dom_sid *sid)
+enum ndr_err_code ndr_push_dom_sid2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct dom_sid *sid)
 {
        if (!(ndr_flags & NDR_SCALARS)) {
                return NDR_ERR_SUCCESS;
@@ -212,7 +212,7 @@ enum ndr_err_code ndr_push_dom_sid2(struct ndr_push *ndr, int ndr_flags, const s
 /*
   parse a dom_sid28 - this is a dom_sid in a fixed 28 byte buffer, so we need to ensure there are only up to 5 sub_auth
 */
-enum ndr_err_code ndr_pull_dom_sid28(struct ndr_pull *ndr, int ndr_flags, struct dom_sid *sid)
+enum ndr_err_code ndr_pull_dom_sid28(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dom_sid *sid)
 {
        enum ndr_err_code status;
        struct ndr_pull *subndr;
@@ -251,7 +251,7 @@ enum ndr_err_code ndr_pull_dom_sid28(struct ndr_pull *ndr, int ndr_flags, struct
 /*
   push a dom_sid28 - this is a dom_sid in a 28 byte fixed buffer
 */
-enum ndr_err_code ndr_push_dom_sid28(struct ndr_push *ndr, int ndr_flags, const struct dom_sid *sid)
+enum ndr_err_code ndr_push_dom_sid28(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct dom_sid *sid)
 {
        uint32_t old_offset;
        uint32_t padding;
@@ -281,7 +281,7 @@ enum ndr_err_code ndr_push_dom_sid28(struct ndr_push *ndr, int ndr_flags, const
 /*
   parse a dom_sid0 - this is a dom_sid in a variable byte buffer, which is maybe empty
 */
-enum ndr_err_code ndr_pull_dom_sid0(struct ndr_pull *ndr, int ndr_flags, struct dom_sid *sid)
+enum ndr_err_code ndr_pull_dom_sid0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dom_sid *sid)
 {
        if (!(ndr_flags & NDR_SCALARS)) {
                return NDR_ERR_SUCCESS;
@@ -298,7 +298,7 @@ enum ndr_err_code ndr_pull_dom_sid0(struct ndr_pull *ndr, int ndr_flags, struct
 /*
   push a dom_sid0 - this is a dom_sid in a variable byte buffer, which is maybe empty
 */
-enum ndr_err_code ndr_push_dom_sid0(struct ndr_push *ndr, int ndr_flags, const struct dom_sid *sid)
+enum ndr_err_code ndr_push_dom_sid0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct dom_sid *sid)
 {
        if (!(ndr_flags & NDR_SCALARS)) {
                return NDR_ERR_SUCCESS;
@@ -315,7 +315,7 @@ enum ndr_err_code ndr_push_dom_sid0(struct ndr_push *ndr, int ndr_flags, const s
        return ndr_push_dom_sid(ndr, ndr_flags, sid);
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_dom_sid(struct ndr_push *ndr, int ndr_flags, const struct dom_sid *r)
+_PUBLIC_ enum ndr_err_code ndr_push_dom_sid(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct dom_sid *r)
 {
        uint32_t cntr_sub_auths_0;
        if (ndr_flags & NDR_SCALARS) {
@@ -333,7 +333,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_dom_sid(struct ndr_push *ndr, int ndr_flags,
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_dom_sid(struct ndr_pull *ndr, int ndr_flags, struct dom_sid *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_dom_sid(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct dom_sid *r)
 {
        uint32_t cntr_sub_auths_0;
        if (ndr_flags & NDR_SCALARS) {
index 4d3101b444d45bab682c360ca3e5cdced6465728..6c5fab5c8cba2228f6f066f1c090f9caa263ba11 100644 (file)
 /*
   spoolss_EnumPrinters
 */
-enum ndr_err_code ndr_push_spoolss_EnumPrinters(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrinters *r)
+enum ndr_err_code ndr_push_spoolss_EnumPrinters(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrinters *r)
 {
        NDR_SPOOLSS_PUSH_ENUM_LEVEL(spoolss_EnumPrinters,{
                _r.in.flags     = r->in.flags;
@@ -331,7 +331,7 @@ enum ndr_err_code ndr_push_spoolss_EnumPrinters(struct ndr_push *ndr, int flags,
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumPrinters(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrinters *r)
+enum ndr_err_code ndr_pull_spoolss_EnumPrinters(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrinters *r)
 {
        NDR_SPOOLSS_PULL_ENUM_LEVEL(spoolss_EnumPrinters,{
                r->in.flags     = _r.in.flags;
@@ -351,7 +351,7 @@ uint32_t ndr_size_spoolss_EnumPrinters_info(TALLOC_CTX *mem_ctx, uint32_t level,
 /*
   spoolss_EnumJobs
 */
-enum ndr_err_code ndr_push_spoolss_EnumJobs(struct ndr_push *ndr, int flags, const struct spoolss_EnumJobs *r)
+enum ndr_err_code ndr_push_spoolss_EnumJobs(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumJobs *r)
 {
        NDR_SPOOLSS_PUSH_ENUM_LEVEL(spoolss_EnumJobs,{
                _r.in.handle    = r->in.handle;
@@ -365,7 +365,7 @@ enum ndr_err_code ndr_push_spoolss_EnumJobs(struct ndr_push *ndr, int flags, con
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumJobs(struct ndr_pull *ndr, int flags, struct spoolss_EnumJobs *r)
+enum ndr_err_code ndr_pull_spoolss_EnumJobs(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumJobs *r)
 {
        NDR_SPOOLSS_PULL_ENUM_LEVEL(spoolss_EnumJobs,{
                r->in.handle    = _r.in.handle;
@@ -387,7 +387,7 @@ uint32_t ndr_size_spoolss_EnumJobs_info(TALLOC_CTX *mem_ctx, uint32_t level, uin
 /*
   spoolss_EnumPrinterDrivers
 */
-enum ndr_err_code ndr_push_spoolss_EnumPrinterDrivers(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrinterDrivers *r)
+enum ndr_err_code ndr_push_spoolss_EnumPrinterDrivers(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrinterDrivers *r)
 {
        NDR_SPOOLSS_PUSH_ENUM_LEVEL(spoolss_EnumPrinterDrivers,{
                _r.in.server            = r->in.server;
@@ -399,7 +399,7 @@ enum ndr_err_code ndr_push_spoolss_EnumPrinterDrivers(struct ndr_push *ndr, int
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumPrinterDrivers(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrinterDrivers *r)
+enum ndr_err_code ndr_pull_spoolss_EnumPrinterDrivers(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrinterDrivers *r)
 {
        NDR_SPOOLSS_PULL_ENUM_LEVEL(spoolss_EnumPrinterDrivers,{
                r->in.server            = _r.in.server;
@@ -419,7 +419,7 @@ uint32_t ndr_size_spoolss_EnumPrinterDrivers_info(TALLOC_CTX *mem_ctx, uint32_t
 /*
   spoolss_EnumForms
 */
-enum ndr_err_code ndr_push_spoolss_EnumForms(struct ndr_push *ndr, int flags, const struct spoolss_EnumForms *r)
+enum ndr_err_code ndr_push_spoolss_EnumForms(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumForms *r)
 {
        NDR_SPOOLSS_PUSH_ENUM_LEVEL(spoolss_EnumForms,{
                _r.in.handle    = r->in.handle;
@@ -429,7 +429,7 @@ enum ndr_err_code ndr_push_spoolss_EnumForms(struct ndr_push *ndr, int flags, co
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumForms(struct ndr_pull *ndr, int flags, struct spoolss_EnumForms *r)
+enum ndr_err_code ndr_pull_spoolss_EnumForms(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumForms *r)
 {
        NDR_SPOOLSS_PULL_ENUM_LEVEL(spoolss_EnumForms,{
                r->in.handle    = _r.in.handle;
@@ -447,7 +447,7 @@ uint32_t ndr_size_spoolss_EnumForms_info(TALLOC_CTX *mem_ctx, uint32_t level, ui
 /*
   spoolss_EnumPorts
 */
-enum ndr_err_code ndr_push_spoolss_EnumPorts(struct ndr_push *ndr, int flags, const struct spoolss_EnumPorts *r)
+enum ndr_err_code ndr_push_spoolss_EnumPorts(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPorts *r)
 {
        NDR_SPOOLSS_PUSH_ENUM_LEVEL(spoolss_EnumPorts,{
                _r.in.servername= r->in.servername;
@@ -457,7 +457,7 @@ enum ndr_err_code ndr_push_spoolss_EnumPorts(struct ndr_push *ndr, int flags, co
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumPorts(struct ndr_pull *ndr, int flags, struct spoolss_EnumPorts *r)
+enum ndr_err_code ndr_pull_spoolss_EnumPorts(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPorts *r)
 {
        NDR_SPOOLSS_PULL_ENUM_LEVEL(spoolss_EnumPorts,{
                r->in.servername= _r.in.servername;
@@ -475,7 +475,7 @@ uint32_t ndr_size_spoolss_EnumPorts_info(TALLOC_CTX *mem_ctx, uint32_t level, ui
 /*
   spoolss_EnumMonitors
 */
-enum ndr_err_code ndr_push_spoolss_EnumMonitors(struct ndr_push *ndr, int flags, const struct spoolss_EnumMonitors *r)
+enum ndr_err_code ndr_push_spoolss_EnumMonitors(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumMonitors *r)
 {
        NDR_SPOOLSS_PUSH_ENUM_LEVEL(spoolss_EnumMonitors,{
                _r.in.servername= r->in.servername;
@@ -485,7 +485,7 @@ enum ndr_err_code ndr_push_spoolss_EnumMonitors(struct ndr_push *ndr, int flags,
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumMonitors(struct ndr_pull *ndr, int flags, struct spoolss_EnumMonitors *r)
+enum ndr_err_code ndr_pull_spoolss_EnumMonitors(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumMonitors *r)
 {
        NDR_SPOOLSS_PULL_ENUM_LEVEL(spoolss_EnumMonitors,{
                r->in.servername= _r.in.servername;
@@ -503,7 +503,7 @@ uint32_t ndr_size_spoolss_EnumMonitors_info(TALLOC_CTX *mem_ctx, uint32_t level,
 /*
   spoolss_EnumPrintProcessors
 */
-enum ndr_err_code ndr_push_spoolss_EnumPrintProcessors(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrintProcessors *r)
+enum ndr_err_code ndr_push_spoolss_EnumPrintProcessors(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrintProcessors *r)
 {
        NDR_SPOOLSS_PUSH_ENUM_LEVEL(spoolss_EnumPrintProcessors,{
                _r.in.servername        = r->in.servername;
@@ -515,7 +515,7 @@ enum ndr_err_code ndr_push_spoolss_EnumPrintProcessors(struct ndr_push *ndr, int
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumPrintProcessors(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrintProcessors *r)
+enum ndr_err_code ndr_pull_spoolss_EnumPrintProcessors(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrintProcessors *r)
 {
        NDR_SPOOLSS_PULL_ENUM_LEVEL(spoolss_EnumPrintProcessors,{
                r->in.servername        = _r.in.servername;
@@ -536,7 +536,7 @@ uint32_t ndr_size_spoolss_EnumPrintProcessors_info(TALLOC_CTX *mem_ctx,
 /*
   spoolss_EnumPrintProcessors
 */
-enum ndr_err_code ndr_push_spoolss_EnumPrintProcessorDataTypes(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrintProcessorDataTypes *r)
+enum ndr_err_code ndr_push_spoolss_EnumPrintProcessorDataTypes(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrintProcessorDataTypes *r)
 {
        NDR_SPOOLSS_PUSH_ENUM_LEVEL(spoolss_EnumPrintProcessorDataTypes,{
                _r.in.servername                = r->in.servername;
@@ -548,7 +548,7 @@ enum ndr_err_code ndr_push_spoolss_EnumPrintProcessorDataTypes(struct ndr_push *
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumPrintProcessorDataTypes(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrintProcessorDataTypes *r)
+enum ndr_err_code ndr_pull_spoolss_EnumPrintProcessorDataTypes(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrintProcessorDataTypes *r)
 {
        NDR_SPOOLSS_PULL_ENUM_LEVEL(spoolss_EnumPrintProcessorDataTypes,{
                r->in.servername                = _r.in.servername;
@@ -569,7 +569,7 @@ uint32_t ndr_size_spoolss_EnumPrintProcessorDataTypes_info(TALLOC_CTX *mem_ctx,
 /*
   spoolss_EnumPerMachineConnections
 */
-enum ndr_err_code ndr_push_spoolss_EnumPerMachineConnections(struct ndr_push *ndr, int flags, const struct spoolss_EnumPerMachineConnections *r)
+enum ndr_err_code ndr_push_spoolss_EnumPerMachineConnections(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPerMachineConnections *r)
 {
        NDR_SPOOLSS_PUSH_ENUM(spoolss_EnumPerMachineConnections,{
                _r.in.server    = r->in.server;
@@ -579,7 +579,7 @@ enum ndr_err_code ndr_push_spoolss_EnumPerMachineConnections(struct ndr_push *nd
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumPerMachineConnections(struct ndr_pull *ndr, int flags, struct spoolss_EnumPerMachineConnections *r)
+enum ndr_err_code ndr_pull_spoolss_EnumPerMachineConnections(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPerMachineConnections *r)
 {
        NDR_SPOOLSS_PULL_ENUM(spoolss_EnumPerMachineConnections,{
                r->in.server    = _r.in.server;
@@ -598,7 +598,7 @@ uint32_t ndr_size_spoolss_EnumPerMachineConnections_info(TALLOC_CTX *mem_ctx, ui
   spoolss_EnumPrinterDataEx
 */
 
-enum ndr_err_code ndr_push_spoolss_EnumPrinterDataEx(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrinterDataEx *r)
+enum ndr_err_code ndr_push_spoolss_EnumPrinterDataEx(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrinterDataEx *r)
 {
        struct _spoolss_EnumPrinterDataEx _r;
        if (flags & NDR_IN) {
@@ -638,7 +638,7 @@ enum ndr_err_code ndr_push_spoolss_EnumPrinterDataEx(struct ndr_push *ndr, int f
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_pull_spoolss_EnumPrinterDataEx(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrinterDataEx *r)
+enum ndr_err_code ndr_pull_spoolss_EnumPrinterDataEx(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrinterDataEx *r)
 {
        struct _spoolss_EnumPrinterDataEx _r;
        if (flags & NDR_IN) {
@@ -697,7 +697,7 @@ uint32_t ndr_size_spoolss_EnumPrinterDataEx_info(TALLOC_CTX *mem_ctx,
        NDR_SPOOLSS_SIZE_ENUM(spoolss_EnumPrinterDataEx);
 }
 
-uint32_t _ndr_size_spoolss_DeviceMode(struct spoolss_DeviceMode *devmode, uint32_t flags)
+uint32_t _ndr_size_spoolss_DeviceMode(struct spoolss_DeviceMode *devmode, ndr_flags_type flags)
 {
        if (!devmode) return 0;
        return ndr_size_spoolss_DeviceMode(devmode, flags);
@@ -715,7 +715,7 @@ _PUBLIC_ size_t ndr_size_spoolss_StringArray(const struct spoolss_StringArray *r
 /* hand marshall as pidl cannot (yet) generate a relative pointer to a fixed array of
  * structs */
 
-_PUBLIC_ enum ndr_err_code ndr_push_spoolss_DriverInfo101(struct ndr_push *ndr, int ndr_flags, const struct spoolss_DriverInfo101 *r)
+_PUBLIC_ enum ndr_err_code ndr_push_spoolss_DriverInfo101(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct spoolss_DriverInfo101 *r)
 {
        uint32_t cntr_file_info_1;
        if (ndr_flags & NDR_SCALARS) {
@@ -889,7 +889,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_spoolss_DriverInfo101(struct ndr_push *ndr,
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_spoolss_DriverInfo101(struct ndr_pull *ndr, int ndr_flags, struct spoolss_DriverInfo101 *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_spoolss_DriverInfo101(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct spoolss_DriverInfo101 *r)
 {
        uint32_t _ptr_driver_name;
        TALLOC_CTX *_mem_save_driver_name_0;
@@ -1267,7 +1267,7 @@ void ndr_print_spoolss_security_descriptor(struct ndr_print *ndr, const char *na
        ndr_print_security_descriptor(ndr, name, r);
 }
 
-enum ndr_err_code ndr_pull_spoolss_security_descriptor(struct ndr_pull *ndr, int ndr_flags, struct security_descriptor *r)
+enum ndr_err_code ndr_pull_spoolss_security_descriptor(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct security_descriptor *r)
 {
        libndr_flags _flags_save_STRUCT = ndr->flags;
        ndr_set_flags(&ndr->flags, LIBNDR_FLAG_NO_RELATIVE_REVERSE);
@@ -1276,7 +1276,7 @@ enum ndr_err_code ndr_pull_spoolss_security_descriptor(struct ndr_pull *ndr, int
        return NDR_ERR_SUCCESS;
 }
 
-enum ndr_err_code ndr_push_spoolss_security_descriptor(struct ndr_push *ndr, int ndr_flags, const struct security_descriptor *r)
+enum ndr_err_code ndr_push_spoolss_security_descriptor(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct security_descriptor *r)
 {
        {
                libndr_flags _flags_save_STRUCT = ndr->flags;
@@ -1318,7 +1318,7 @@ enum ndr_err_code ndr_push_spoolss_security_descriptor(struct ndr_push *ndr, int
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_spoolss_PrinterInfo2(struct ndr_push *ndr, int ndr_flags, const struct spoolss_PrinterInfo2 *r)
+_PUBLIC_ enum ndr_err_code ndr_push_spoolss_PrinterInfo2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct spoolss_PrinterInfo2 *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                NDR_CHECK(ndr_push_align(ndr, 5));
index ef752ebf7ba2650e63ca28a94813ddec187ecdfd..25b6ae54725df86fbb2e1232ba8d01d1c9c38422 100644 (file)
 
 /* The following definitions come from /space/src/samba/SOURCES/samba.git/source3/../source4/librpc/ndr/ndr_spoolss_buf.c  */
 
-enum ndr_err_code ndr_push_spoolss_EnumPrinters(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrinters *r);
-enum ndr_err_code ndr_pull_spoolss_EnumPrinters(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrinters *r);
+enum ndr_err_code ndr_push_spoolss_EnumPrinters(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrinters *r);
+enum ndr_err_code ndr_pull_spoolss_EnumPrinters(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrinters *r);
 uint32_t ndr_size_spoolss_EnumPrinters_info(TALLOC_CTX *mem_ctx, uint32_t level, uint32_t count, union spoolss_PrinterInfo *info);
-enum ndr_err_code ndr_push_spoolss_EnumJobs(struct ndr_push *ndr, int flags, const struct spoolss_EnumJobs *r);
-enum ndr_err_code ndr_pull_spoolss_EnumJobs(struct ndr_pull *ndr, int flags, struct spoolss_EnumJobs *r);
+enum ndr_err_code ndr_push_spoolss_EnumJobs(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumJobs *r);
+enum ndr_err_code ndr_pull_spoolss_EnumJobs(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumJobs *r);
 uint32_t ndr_size_spoolss_EnumJobs_info(TALLOC_CTX *mem_ctx, uint32_t level, uint32_t count, union spoolss_JobInfo *info);
-enum ndr_err_code ndr_push_spoolss_EnumPrinterDrivers(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrinterDrivers *r);
-enum ndr_err_code ndr_pull_spoolss_EnumPrinterDrivers(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrinterDrivers *r);
+enum ndr_err_code ndr_push_spoolss_EnumPrinterDrivers(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrinterDrivers *r);
+enum ndr_err_code ndr_pull_spoolss_EnumPrinterDrivers(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrinterDrivers *r);
 uint32_t ndr_size_spoolss_EnumPrinterDrivers_info(TALLOC_CTX *mem_ctx, uint32_t level, uint32_t count, union spoolss_DriverInfo *info);
-enum ndr_err_code ndr_push_spoolss_EnumForms(struct ndr_push *ndr, int flags, const struct spoolss_EnumForms *r);
-enum ndr_err_code ndr_pull_spoolss_EnumForms(struct ndr_pull *ndr, int flags, struct spoolss_EnumForms *r);
+enum ndr_err_code ndr_push_spoolss_EnumForms(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumForms *r);
+enum ndr_err_code ndr_pull_spoolss_EnumForms(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumForms *r);
 uint32_t ndr_size_spoolss_EnumForms_info(TALLOC_CTX *mem_ctx, uint32_t level, uint32_t count, union spoolss_FormInfo *info);
-enum ndr_err_code ndr_push_spoolss_EnumPorts(struct ndr_push *ndr, int flags, const struct spoolss_EnumPorts *r);
-enum ndr_err_code ndr_pull_spoolss_EnumPorts(struct ndr_pull *ndr, int flags, struct spoolss_EnumPorts *r);
+enum ndr_err_code ndr_push_spoolss_EnumPorts(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPorts *r);
+enum ndr_err_code ndr_pull_spoolss_EnumPorts(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPorts *r);
 uint32_t ndr_size_spoolss_EnumPorts_info(TALLOC_CTX *mem_ctx, uint32_t level, uint32_t count, union spoolss_PortInfo *info);
-enum ndr_err_code ndr_push_spoolss_EnumMonitors(struct ndr_push *ndr, int flags, const struct spoolss_EnumMonitors *r);
-enum ndr_err_code ndr_pull_spoolss_EnumMonitors(struct ndr_pull *ndr, int flags, struct spoolss_EnumMonitors *r);
+enum ndr_err_code ndr_push_spoolss_EnumMonitors(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumMonitors *r);
+enum ndr_err_code ndr_pull_spoolss_EnumMonitors(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumMonitors *r);
 uint32_t ndr_size_spoolss_EnumMonitors_info(TALLOC_CTX *mem_ctx, uint32_t level, uint32_t count, union spoolss_MonitorInfo *info);
-enum ndr_err_code ndr_push_spoolss_EnumPrintProcessors(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrintProcessors *r);
-enum ndr_err_code ndr_pull_spoolss_EnumPrintProcessors(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrintProcessors *r);
+enum ndr_err_code ndr_push_spoolss_EnumPrintProcessors(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrintProcessors *r);
+enum ndr_err_code ndr_pull_spoolss_EnumPrintProcessors(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrintProcessors *r);
 uint32_t ndr_size_spoolss_EnumPrintProcessors_info(TALLOC_CTX *mem_ctx,
                                                   uint32_t level, uint32_t count, union spoolss_PrintProcessorInfo *info);
-enum ndr_err_code ndr_push_spoolss_EnumPrintProcessorDataTypes(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrintProcessorDataTypes *r);
-enum ndr_err_code ndr_pull_spoolss_EnumPrintProcessorDataTypes(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrintProcessorDataTypes *r);
+enum ndr_err_code ndr_push_spoolss_EnumPrintProcessorDataTypes(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrintProcessorDataTypes *r);
+enum ndr_err_code ndr_pull_spoolss_EnumPrintProcessorDataTypes(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrintProcessorDataTypes *r);
 uint32_t ndr_size_spoolss_EnumPrintProcessorDataTypes_info(TALLOC_CTX *mem_ctx,
                                                      uint32_t level, uint32_t count, union spoolss_PrintProcDataTypesInfo *info);
-enum ndr_err_code ndr_push_spoolss_EnumPrinterDataEx(struct ndr_push *ndr, int flags, const struct spoolss_EnumPrinterDataEx *r);
-enum ndr_err_code ndr_pull_spoolss_EnumPrinterDataEx(struct ndr_pull *ndr, int flags, struct spoolss_EnumPrinterDataEx *r);
+enum ndr_err_code ndr_push_spoolss_EnumPrinterDataEx(struct ndr_push *ndr, ndr_flags_type flags, const struct spoolss_EnumPrinterDataEx *r);
+enum ndr_err_code ndr_pull_spoolss_EnumPrinterDataEx(struct ndr_pull *ndr, ndr_flags_type flags, struct spoolss_EnumPrinterDataEx *r);
 uint32_t ndr_size_spoolss_EnumPrinterDataEx_info(TALLOC_CTX *mem_ctx, 
                                                 uint32_t count, struct spoolss_PrinterEnumValues *info);
-uint32_t _ndr_size_spoolss_DeviceMode(struct spoolss_DeviceMode *devmode, uint32_t flags);
+uint32_t _ndr_size_spoolss_DeviceMode(struct spoolss_DeviceMode *devmode, ndr_flags_type flags);
 size_t ndr_size_spoolss_StringArray(const struct spoolss_StringArray *r, libndr_flags flags);
-_PUBLIC_ enum ndr_err_code ndr_push_spoolss_DriverInfo101(struct ndr_push *ndr, int ndr_flags, const struct spoolss_DriverInfo101 *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_spoolss_DriverInfo101(struct ndr_pull *ndr, int ndr_flags, struct spoolss_DriverInfo101 *r);
+_PUBLIC_ enum ndr_err_code ndr_push_spoolss_DriverInfo101(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct spoolss_DriverInfo101 *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_spoolss_DriverInfo101(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct spoolss_DriverInfo101 *r);
 void ndr_print_spoolss_Field(struct ndr_print *ndr, const char *name, const union spoolss_Field *r);
 size_t ndr_size_spoolss_PrinterData(const union spoolss_PrinterData *r, uint32_t level, libndr_flags flags);
 void ndr_print_spoolss_security_descriptor(struct ndr_print *ndr, const char *name, const struct security_descriptor *r);
-enum ndr_err_code ndr_pull_spoolss_security_descriptor(struct ndr_pull *ndr, int ndr_flags, struct security_descriptor *r);
-enum ndr_err_code ndr_push_spoolss_security_descriptor(struct ndr_push *ndr, int ndr_flags, const struct security_descriptor *r);
+enum ndr_err_code ndr_pull_spoolss_security_descriptor(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct security_descriptor *r);
+enum ndr_err_code ndr_push_spoolss_security_descriptor(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct security_descriptor *r);
 _PUBLIC_ void ndr_print_spoolss_Time(struct ndr_print *ndr, const char *name, const struct spoolss_Time *r);
 _PUBLIC_ libndr_flags ndr_spoolss_PrinterEnumValues_align(enum winreg_Type type);
 
index 7980ca14759ecbd8d5605cc0ad0fa7a4604233c1..d0b64dc6fd90ab841f8dfc7c5566c5132abc55c3 100644 (file)
@@ -25,7 +25,7 @@
 /**
   pull a general string from the wire
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_string(struct ndr_pull *ndr, int ndr_flags, const char **s)
+_PUBLIC_ enum ndr_err_code ndr_pull_string(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **s)
 {
        char *as=NULL;
        uint32_t len1, ofs, len2;
@@ -199,7 +199,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_string(struct ndr_pull *ndr, int ndr_flags,
 /**
   push a general string onto the wire
 */
-_PUBLIC_ enum ndr_err_code ndr_push_string(struct ndr_push *ndr, int ndr_flags, const char *s)
+_PUBLIC_ enum ndr_err_code ndr_push_string(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *s)
 {
        ssize_t s_len, c_len;
        size_t d_len;
@@ -354,14 +354,14 @@ _PUBLIC_ void ndr_print_string(struct ndr_print *ndr, const char *name, const ch
        }
 }
 
-_PUBLIC_ uint32_t ndr_size_string(int ret, const char * const* string, int flags)
+_PUBLIC_ uint32_t ndr_size_string(int ret, const char * const* string, ndr_flags_type flags)
 {
        /* FIXME: Is this correct for all strings ? */
        if(!(*string)) return ret;
        return ret+strlen(*string)+1;
 }
 
-static uint32_t guess_string_array_size(struct ndr_pull *ndr, int ndr_flags)
+static uint32_t guess_string_array_size(struct ndr_pull *ndr, ndr_flags_type ndr_flags)
 {
        /*
         * Here we could do something clever like count the number of zeros in
@@ -402,7 +402,7 @@ static enum ndr_err_code extend_string_array(struct ndr_pull *ndr,
 /**
   pull a general string array from the wire
 */
-_PUBLIC_ enum ndr_err_code ndr_pull_string_array(struct ndr_pull *ndr, int ndr_flags, const char ***_a)
+_PUBLIC_ enum ndr_err_code ndr_pull_string_array(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char ***_a)
 {
        const char **a = NULL;
        uint32_t count;
@@ -509,7 +509,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_string_array(struct ndr_pull *ndr, int ndr_f
 /**
   push a general string array onto the wire
 */
-_PUBLIC_ enum ndr_err_code ndr_push_string_array(struct ndr_push *ndr, int ndr_flags, const char **a)
+_PUBLIC_ enum ndr_err_code ndr_push_string_array(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char **a)
 {
        uint32_t count;
        libndr_flags flags = ndr->flags;
@@ -691,7 +691,7 @@ _PUBLIC_ enum ndr_err_code ndr_check_string_terminator(struct ndr_pull *ndr, uin
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_charset(struct ndr_pull *ndr, int ndr_flags, const char **var, uint32_t length, uint8_t byte_mul, charset_t chset)
+_PUBLIC_ enum ndr_err_code ndr_pull_charset(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **var, uint32_t length, uint8_t byte_mul, charset_t chset)
 {
        size_t converted_size;
 
@@ -722,7 +722,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_charset(struct ndr_pull *ndr, int ndr_flags,
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_charset_to_null(struct ndr_pull *ndr, int ndr_flags, const char **var, uint32_t length, uint8_t byte_mul, charset_t chset)
+_PUBLIC_ enum ndr_err_code ndr_pull_charset_to_null(struct ndr_pull *ndr, ndr_flags_type ndr_flags, const char **var, uint32_t length, uint8_t byte_mul, charset_t chset)
 {
        size_t converted_size;
        uint32_t str_len;
@@ -760,7 +760,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_charset_to_null(struct ndr_pull *ndr, int nd
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_charset(struct ndr_push *ndr, int ndr_flags, const char *var, uint32_t length, uint8_t byte_mul, charset_t chset)
+_PUBLIC_ enum ndr_err_code ndr_push_charset(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *var, uint32_t length, uint8_t byte_mul, charset_t chset)
 {
        size_t required;
 
@@ -800,7 +800,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_charset(struct ndr_push *ndr, int ndr_flags,
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_push_charset_to_null(struct ndr_push *ndr, int ndr_flags, const char *var, uint32_t length, uint8_t byte_mul, charset_t chset)
+_PUBLIC_ enum ndr_err_code ndr_push_charset_to_null(struct ndr_push *ndr, ndr_flags_type ndr_flags, const char *var, uint32_t length, uint8_t byte_mul, charset_t chset)
 {
        const char *str = var;
 
index ac9aff008c67ab9a66d60eb4c3e86068ebafa336..85ba62ea774d5b37a35feb60aa3092e792a8ae3f 100644 (file)
@@ -22,7 +22,7 @@
 #include "includes.h"
 #include "librpc/gen_ndr/ndr_witness.h"
 
-_PUBLIC_ enum ndr_err_code ndr_push_witness_notifyResponse(struct ndr_push *ndr, int ndr_flags, const struct witness_notifyResponse *r)
+_PUBLIC_ enum ndr_err_code ndr_push_witness_notifyResponse(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct witness_notifyResponse *r)
 {
        uint32_t cntr_messages_0;
        {
@@ -58,7 +58,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_witness_notifyResponse(struct ndr_push *ndr,
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_witness_notifyResponse(struct ndr_pull *ndr, int ndr_flags, struct witness_notifyResponse *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_witness_notifyResponse(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct witness_notifyResponse *r)
 {
        libndr_flags _flags_save_STRUCT = ndr->flags;
        ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
index e4dd3df63c6da59f03015fff0efcd44089081558..1a129e6b59c70782f7fc3de19cc6cef4590699c8 100644 (file)
@@ -19,5 +19,5 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
 
-_PUBLIC_ enum ndr_err_code ndr_push_witness_notifyResponse(struct ndr_push *ndr, int ndr_flags, const struct witness_notifyResponse *r);
-_PUBLIC_ enum ndr_err_code ndr_pull_witness_notifyResponse(struct ndr_pull *ndr, int ndr_flags, struct witness_notifyResponse *r);
+_PUBLIC_ enum ndr_err_code ndr_push_witness_notifyResponse(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct witness_notifyResponse *r);
+_PUBLIC_ enum ndr_err_code ndr_pull_witness_notifyResponse(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct witness_notifyResponse *r);
index 62d2c535cd8beaeac9cd14f04f93a7be46992aae..7787bb16b54ce501e18d98aee43124ce0aabf038 100644 (file)
@@ -20,5 +20,5 @@
    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 */
 
-enum ndr_err_code ndr_push_BSTR(struct ndr_push *ndr, int ndr_flags, const struct BSTR *r);
-enum ndr_err_code ndr_pull_BSTR(struct ndr_pull *ndr, int ndr_flags, struct BSTR *r);
+enum ndr_err_code ndr_push_BSTR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct BSTR *r);
+enum ndr_err_code ndr_pull_BSTR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct BSTR *r);
index 5a343e06f29c974b36f7854da87b5af757d3d6ce..0ffdce9c881359a349b497a3dce10eabb63f2956 100644 (file)
@@ -57,7 +57,7 @@ static char *ndr_compat_xattr_attrib_hex(TALLOC_CTX *mem_ctx,
 }
 
 _PUBLIC_ enum ndr_err_code ndr_push_xattr_DOSATTRIB(struct ndr_push *ndr,
-                                               int ndr_flags,
+                                               ndr_flags_type ndr_flags,
                                                const struct xattr_DOSATTRIB *r)
 {
        if (ndr_flags & NDR_SCALARS) {
@@ -85,7 +85,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_xattr_DOSATTRIB(struct ndr_push *ndr,
        return NDR_ERR_SUCCESS;
 }
 
-_PUBLIC_ enum ndr_err_code ndr_pull_xattr_DOSATTRIB(struct ndr_pull *ndr, int ndr_flags, struct xattr_DOSATTRIB *r)
+_PUBLIC_ enum ndr_err_code ndr_pull_xattr_DOSATTRIB(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct xattr_DOSATTRIB *r)
 {
        if (ndr_flags & NDR_SCALARS) {
                NDR_CHECK(ndr_pull_align(ndr, 4));
index bdc530a0ae76f3a2eba9a8a39db0c90602d3ab85..893ac882166df88ce7daf7491a8670b1cddef6a1 100644 (file)
 #define _LIBRPC_NDR_NDR_XATTR_H
 
 _PUBLIC_ enum ndr_err_code ndr_push_xattr_DOSATTRIB(struct ndr_push *ndr,
-                                               int ndr_flags,
+                                               ndr_flags_type ndr_flags,
                                                const struct xattr_DOSATTRIB *r);
 
 _PUBLIC_ enum ndr_err_code ndr_pull_xattr_DOSATTRIB(struct ndr_pull *ndr,
-                                               int ndr_flags,
+                                               ndr_flags_type ndr_flags,
                                                struct xattr_DOSATTRIB *r);
 
 _PUBLIC_ void ndr_print_xattr_DOSATTRIB(struct ndr_print *ndr,
index 5aaca50919faa78d6ae2d26376919580eb6ba2e9..5eb9c445ab25d785b20ee0efa7d01c00403dc8c7 100644 (file)
@@ -384,7 +384,7 @@ void dcerpc_save_ndr_fuzz_seed(TALLOC_CTX *mem_ctx,
                               DATA_BLOB raw_blob,
                               const char *dump_dir,
                               const char *iface_name,
-                              int flags,
+                              ndr_flags_type flags,
                               int opnum,
                               bool ndr64)
 {
index cd15a87fa08dc222c377af011011652816c9696b..e6f7fa634a92749e2ef61c993140efd3df918c26 100644 (file)
@@ -1106,7 +1106,7 @@ NTSTATUS dcerpc_ncacn_push_auth(DATA_BLOB *blob,
 */
 void dcerpc_log_packet(const char *packet_log_dir,
                       const char *interface_name,
-                      uint32_t opnum, uint32_t flags,
+                      uint32_t opnum, ndr_flags_type flags,
                       const DATA_BLOB *pkt,
                       const char *why)
 {
index 00ac8e421e361a20dcfb55f528abb6eed2132e47..24f619d7337ba501f97bfa58344b4f7ae4686a1c 100644 (file)
@@ -1882,7 +1882,7 @@ static void dcesrv_save_call(struct dcesrv_call_state *call, const char *why)
 */
 void _dcesrv_save_ndr_fuzz_seed(DATA_BLOB call_blob,
                                struct dcesrv_call_state *call,
-                               int flags)
+                               ndr_flags_type flags)
 {
        const char *dump_dir = lpcfg_parm_string(call->conn->dce_ctx->lp_ctx,
                                                 NULL,
index b03376dad48890984931a8a45295b98e11fff6e5..e45c85a7f7f7cdc30fa664e3667293cf506d1e48 100644 (file)
@@ -689,7 +689,7 @@ _PUBLIC_ const struct dcesrv_interface *find_interface_by_syntax_id(
 
 void _dcesrv_save_ndr_fuzz_seed(DATA_BLOB call_blob,
                                struct dcesrv_call_state *call,
-                               int flags);
+                               ndr_flags_type flags);
 
 #if DEVELOPER
 #define  dcesrv_save_ndr_fuzz_seed(stub, call, flags) \
index b1c585447d275973ee3376c3d9dc970b26939d0d..76557101dcda162029310be3b545f968c5fd3c94 100644 (file)
@@ -27,6 +27,8 @@
 #include "gen_ndr/dcerpc.h"
 #include "lib/util/attr.h"
 
+#include "librpc/ndr/libndr.h"
+
 struct dcerpc_binding_handle;
 struct GUID;
 struct ndr_interface_table;
@@ -202,7 +204,7 @@ struct dcerpc_binding_handle_ops {
        bool (*ref_alloc)(struct dcerpc_binding_handle *h);
        bool (*use_ndr64)(struct dcerpc_binding_handle *h);
        void (*do_ndr_print)(struct dcerpc_binding_handle *h,
-                            int ndr_flags,
+                            ndr_flags_type ndr_flags,
                             const void *struct_ptr,
                             const struct ndr_interface_call *call);
        void (*ndr_push_failed)(struct dcerpc_binding_handle *h,
@@ -382,7 +384,7 @@ NTSTATUS dcerpc_ncacn_push_auth(DATA_BLOB *blob,
 
 void dcerpc_log_packet(const char *packet_log_dir,
                       const char *interface_name,
-                      uint32_t opnum, uint32_t flags,
+                      uint32_t opnum, ndr_flags_type flags,
                       const DATA_BLOB *pkt,
                       const char *why);
 
@@ -391,7 +393,7 @@ void dcerpc_save_ndr_fuzz_seed(TALLOC_CTX *mem_ctx,
                               DATA_BLOB raw_blob,
                               const char *dump_dir,
                               const char *iface_name,
-                              int flags,
+                              ndr_flags_type flags,
                               int opnum,
                               bool ndr64);
 #else
@@ -399,7 +401,7 @@ static inline void dcerpc_save_ndr_fuzz_seed(TALLOC_CTX *mem_ctx,
                                             DATA_BLOB raw_blob,
                                             const char *dump_dir,
                                             const char *iface_name,
-                                            int flags,
+                                            ndr_flags_type flags,
                                             int opnum,
                                             bool ndr64)
 {
index 24ec93b17d565aa78829b804a7c1e0ff9848fd8d..7c8ded4df42a0f29c76b668b06c37087f82a83d4 100644 (file)
@@ -46,7 +46,7 @@ static void test_pull_string_zero_len_nul_term(void **state)
 {
        struct ndr_pull ndr = {0};
        enum ndr_err_code err;
-       int flags = NDR_SCALARS;
+       ndr_flags_type flags = NDR_SCALARS;
        uint8_t data[] = {0x0, 0x0};
        const char *s = NULL;
 
@@ -76,7 +76,7 @@ static void test_pull_string_len_1_nul_term(void **state)
 {
        struct ndr_pull ndr = {0};
        enum ndr_err_code err;
-       int flags = NDR_SCALARS;
+       ndr_flags_type flags = NDR_SCALARS;
        const char *s = NULL;
        uint8_t data[] = {0x0, 0x0};
 
@@ -103,7 +103,7 @@ static void test_pull_string_len_2_nul_term(void **state)
 {
        struct ndr_pull ndr = {0};
        enum ndr_err_code err;
-       int flags = NDR_SCALARS;
+       ndr_flags_type flags = NDR_SCALARS;
        const char *s;
        uint8_t data[] = {0x0, 0x0};
 
index a81d8062443e258e447d2bcd1c6090c7d1dbb7dc..528e1fa5473c21f4a09f5f1c8fe488e5c4c2f52a 100644 (file)
@@ -280,7 +280,7 @@ static void ndr_print_dummy(struct ndr_print *ndr, const char *format, ...)
        struct ndr_pull *ndr_pull;
        struct ndr_print *ndr_print;
        TALLOC_CTX *mem_ctx;
-       int flags = 0;
+       ndr_flags_type flags = 0;
        poptContext pc;
        NTSTATUS status;
        enum ndr_err_code ndr_err;
index 8832b9b3127399a2d99ed451794992434235c8b1..56597df41879169d8cd56ca39f185f91a7162cb2 100644 (file)
@@ -85,6 +85,7 @@ my $scalar_alignment = {
        'dnsp_string' => 1,
        'HRESULT' => 4,
        'libndr_flags' => 4,
+       'ndr_flags_type' => 4,
 };
 
 sub GetElementLevelTable($$$)
index 3f7f250209017dabbdf18b3f107ce6609d0841e0..d08497ee3ce8fb1d5c238001f8ea3bdd95b297f7 100644 (file)
@@ -2346,7 +2346,7 @@ sub ParsePipePushChunk($$)
 
        my $args = $typefamily{$struct->{TYPE}}->{DECL}->($struct, "push", $name, $varname);
 
-       $self->fn_declare("push", $struct, "enum ndr_err_code ndr_push_$name(struct ndr_push *$ndr, int ndr_flags, $args)") or return;
+       $self->fn_declare("push", $struct, "enum ndr_err_code ndr_push_$name(struct ndr_push *$ndr, ndr_flags_type ndr_flags, $args)") or return;
 
        return if has_property($t, "nopush");
 
@@ -2379,7 +2379,7 @@ sub ParsePipePullChunk($$)
 
        my $args = $typefamily{$struct->{TYPE}}->{DECL}->($struct, "pull", $name, $varname);
 
-       $self->fn_declare("pull", $struct, "enum ndr_err_code ndr_pull_$name(struct ndr_pull *$ndr, int ndr_flags, $args)") or return;
+       $self->fn_declare("pull", $struct, "enum ndr_err_code ndr_pull_$name(struct ndr_pull *$ndr, ndr_flags_type ndr_flags, $args)") or return;
 
        return if has_property($struct, "nopull");
 
@@ -2432,11 +2432,11 @@ sub ParseFunctionPrint($$)
        my($self, $fn) = @_;
        my $ndr = "ndr";
 
-       $self->pidl_hdr("void ndr_print_$fn->{NAME}(struct ndr_print *$ndr, const char *name, int flags, const struct $fn->{NAME} *r);");
+       $self->pidl_hdr("void ndr_print_$fn->{NAME}(struct ndr_print *$ndr, const char *name, ndr_flags_type flags, const struct $fn->{NAME} *r);");
 
        return if has_property($fn, "noprint");
 
-       $self->pidl("_PUBLIC_ void ndr_print_$fn->{NAME}(struct ndr_print *$ndr, const char *name, int flags, const struct $fn->{NAME} *r)");
+       $self->pidl("_PUBLIC_ void ndr_print_$fn->{NAME}(struct ndr_print *$ndr, const char *name, ndr_flags_type flags, const struct $fn->{NAME} *r)");
        $self->pidl("{");
        $self->indent;
 
@@ -2499,7 +2499,7 @@ sub ParseFunctionPush($$)
        my($self, $fn) = @_;
        my $ndr = "ndr";
 
-       $self->fn_declare("push", $fn, "enum ndr_err_code ndr_push_$fn->{NAME}(struct ndr_push *$ndr, int flags, const struct $fn->{NAME} *r)") or return;
+       $self->fn_declare("push", $fn, "enum ndr_err_code ndr_push_$fn->{NAME}(struct ndr_push *$ndr, ndr_flags_type flags, const struct $fn->{NAME} *r)") or return;
 
        return if has_property($fn, "nopush");
 
@@ -2594,7 +2594,7 @@ sub ParseFunctionPull($$)
        my $ndr = "ndr";
 
        # pull function args
-       $self->fn_declare("pull", $fn, "enum ndr_err_code ndr_pull_$fn->{NAME}(struct ndr_pull *$ndr, int flags, struct $fn->{NAME} *r)") or return;
+       $self->fn_declare("pull", $fn, "enum ndr_err_code ndr_pull_$fn->{NAME}(struct ndr_pull *$ndr, ndr_flags_type flags, struct $fn->{NAME} *r)") or return;
 
        $self->pidl("{");
        $self->indent;
@@ -3059,7 +3059,7 @@ sub ParseTypePushFunction($$$)
 
        my $args = $typefamily{$e->{TYPE}}->{DECL}->($e, "push", $e->{NAME}, $varname);
 
-       $self->fn_declare("push", $e, "enum ndr_err_code ".TypeFunctionName("ndr_push", $e)."(struct ndr_push *$ndr, int ndr_flags, $args)") or return;
+       $self->fn_declare("push", $e, "enum ndr_err_code ".TypeFunctionName("ndr_push", $e)."(struct ndr_push *$ndr, ndr_flags_type ndr_flags, $args)") or return;
 
        $self->pidl("{");
        $self->indent;
@@ -3088,7 +3088,7 @@ sub ParseTypePullFunction($$)
 
        my $args = $typefamily{$e->{TYPE}}->{DECL}->($e, "pull", $e->{NAME}, $varname);
 
-       $self->fn_declare("pull", $e, "enum ndr_err_code ".TypeFunctionName("ndr_pull", $e)."(struct ndr_pull *$ndr, int ndr_flags, $args)") or return;
+       $self->fn_declare("pull", $e, "enum ndr_err_code ".TypeFunctionName("ndr_pull", $e)."(struct ndr_pull *$ndr, ndr_flags_type ndr_flags, $args)") or return;
 
        $self->pidl("{");
        $self->indent;
@@ -3117,7 +3117,7 @@ sub ParseTypePrintFunction($$$)
 
        if (is_public_struct($e)) {
                 $self->pidl("static void ".TypeFunctionName("ndr_print_flags", $e).
-                             "(struct ndr_print *$ndr, const char *name, int unused, $args)"
+                             "(struct ndr_print *$ndr, const char *name, ndr_flags_type unused, $args)"
                              );
                $self->pidl("{");
                $self->indent;
index ac54c4e9b3857594473c5134c415df41721a2999..821cf441a60ff933f83df79c612bbd0958d7e40b 100644 (file)
@@ -543,7 +543,7 @@ sub PythonFunctionStruct($$$$)
        $self->pidl("}");
        $self->pidl("");
 
-       $self->pidl("static PyObject *py_$name\_ndr_pack(PyObject *py_obj, int ndr_inout_flags, libndr_flags ndr_push_flags)");
+       $self->pidl("static PyObject *py_$name\_ndr_pack(PyObject *py_obj, ndr_flags_type ndr_inout_flags, libndr_flags ndr_push_flags)");
        $self->pidl("{");
        $self->indent;
        $self->pidl("$ndr_call");
@@ -658,7 +658,7 @@ sub PythonFunctionStruct($$$$)
        $self->pidl("}");
        $self->pidl("");
 
-       $self->pidl("static PyObject *py_$name\_ndr_unpack(PyObject *py_obj, const DATA_BLOB *blob, int ndr_inout_flags, libndr_flags ndr_pull_flags, bool allow_remaining)");
+       $self->pidl("static PyObject *py_$name\_ndr_unpack(PyObject *py_obj, const DATA_BLOB *blob, ndr_flags_type ndr_inout_flags, libndr_flags ndr_pull_flags, bool allow_remaining)");
        $self->pidl("{");
        $self->indent;
        $self->pidl("$ndr_call");
@@ -823,7 +823,7 @@ sub PythonFunctionStruct($$$$)
        $self->pidl("}");
        $self->pidl("");
 
-       $self->pidl("static PyObject *py_$name\_ndr_print(PyObject *py_obj, const char *name, int ndr_inout_flags)");
+       $self->pidl("static PyObject *py_$name\_ndr_print(PyObject *py_obj, const char *name, ndr_flags_type ndr_inout_flags)");
        $self->pidl("{");
        $self->indent;
        $self->pidl("$ndr_call");
index c6e95675eabbf4bef6793933a0ebc059dd7def78..b86312ed54f39617074aa5ecdaf8633fd9e22d48 100644 (file)
@@ -73,6 +73,7 @@ my %scalars = (
        "dnsp_name"     => "const char *",
        "dnsp_string"   => "const char *",
        "libndr_flags"  => "libndr_flags",
+       "ndr_flags_type"=> "ndr_flags_type",
 );
 
 my %aliases = (
index d19f8621c154d8273212c75fd52fd02c14d7d1d2..6b6e11aa43c30050399e38fe223f861b13aa8df2 100644 (file)
 #include "includes.h"
 #include "librpc/gen_ndr/ndr_ads.h"
 
-enum ndr_err_code ndr_pull_ads_struct(struct ndr_pull *ndr, int ndr_flags, struct ads_struct *r)
+enum ndr_err_code ndr_pull_ads_struct(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ads_struct *r)
 {
        return NDR_ERR_SUCCESS;
 }
-enum ndr_err_code ndr_push_ads_struct(struct ndr_push *ndr, int ndr_flags, const struct ads_struct *r)
+enum ndr_err_code ndr_push_ads_struct(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ads_struct *r)
 {
        return NDR_ERR_SUCCESS;
 }
index 45cd32800459df7b901d4b66fe56fa79c008c82f..1f92960639ec54809ae68f05bbe7fd950c50b4d7 100644 (file)
@@ -584,7 +584,7 @@ NTSTATUS fill_quota_buffer(TALLOC_CTX *mem_ctx,
                              DATA_BLOB *blob,
                              SMB_NTQUOTA_LIST **end_ptr)
 {
-       int ndr_flags = NDR_SCALARS | NDR_BUFFERS;
+       ndr_flags_type ndr_flags = NDR_SCALARS | NDR_BUFFERS;
        struct ndr_push *qndr = NULL;
        uint32_t start_offset = 0;
        uint32_t padding = 0;
index 569d5f8efbb69e129d688f3aa364b9227174e908..b4289e9d35d7070897b5a8f5d6bd6b4a94dc1cca 100644 (file)
@@ -2299,7 +2299,7 @@ static bool rpccli_bh_ref_alloc(struct dcerpc_binding_handle *h)
 }
 
 static void rpccli_bh_do_ndr_print(struct dcerpc_binding_handle *h,
-                                  int ndr_flags,
+                                  ndr_flags_type ndr_flags,
                                   const void *_struct_ptr,
                                   const struct ndr_interface_call *call)
 {
index 5f0dec1517f0747277be19a79b3e9c6a79aa3ba6..91e5ebb3b55d9b71c56ffef8ca759ada1c7ab663 100644 (file)
@@ -552,7 +552,7 @@ bool init_connectin_request(TALLOC_CTX *ctx,
        struct connectin_extpropsets *ext_props = NULL;
        DATA_BLOB props_blob = data_blob_null;
        struct ndr_push *ndr_props = NULL;
-       int ndr_flags = NDR_SCALARS | NDR_BUFFERS;
+       ndr_flags_type ndr_flags = NDR_SCALARS | NDR_BUFFERS;
        bool result;
        struct wsp_cpmconnectin *connectin =
                &request->message.cpmconnect;
@@ -767,7 +767,7 @@ static bool extract_rowbuf_variable_type(TALLOC_CTX *ctx,
 {
        enum ndr_err_code err;
        struct ndr_pull *ndr_pull = NULL;
-       int ndr_flags = NDR_SCALARS | NDR_BUFFERS;
+       ndr_flags_type ndr_flags = NDR_SCALARS | NDR_BUFFERS;
        DATA_BLOB variant_blob = data_blob_null;
        if (offset >= rows_buf->length) {
                DBG_ERR("offset %d outside buffer range (buf len - %zu)",
@@ -901,7 +901,7 @@ static enum ndr_err_code extract_variant_addresses(TALLOC_CTX *ctx,
                               struct wsp_ctablevariant *tablevar,
                               bool is_64bit,
                               struct ndr_pull *ndr_pull,
-                              int flags,
+                              ndr_flags_type flags,
                               uint32_t offset,
                               DATA_BLOB *rows_buf,
                               uint64_t *pcount,
@@ -1009,7 +1009,7 @@ static enum ndr_err_code extract_crowvariant_variable(TALLOC_CTX *ctx,
        struct wsp_ctablevariant *tablevar,
        bool is_64bit,
        struct ndr_pull *ndr_pull,
-       int flags,
+       ndr_flags_type flags,
        uint32_t offset,
        DATA_BLOB *rows_buf,
        uint32_t len,
@@ -1115,7 +1115,7 @@ static enum ndr_err_code extract_crowvariant(TALLOC_CTX *ctx,
                               struct wsp_ctablevariant *tablevar,
                               bool is_64bit,
                               struct ndr_pull *ndr_pull,
-                              int flags,
+                              ndr_flags_type flags,
                               uint32_t offset,
                               DATA_BLOB *rows_buf, uint32_t len,
                               struct wsp_cbasestoragevariant *val)
@@ -1169,7 +1169,7 @@ static enum ndr_err_code process_columns(TALLOC_CTX *ctx,
        uint32_t i;
        enum ndr_err_code err  = NDR_ERR_SUCCESS;
        struct ndr_pull *ndr_pull = NULL;
-       int ndr_flags = NDR_SCALARS | NDR_BUFFERS;
+       ndr_flags_type ndr_flags = NDR_SCALARS | NDR_BUFFERS;
        uint64_t nrow_offset = nrow * bindingin->brow;
 
        if (nrow_offset >= rows_buf->length) {
@@ -1869,7 +1869,7 @@ static enum ndr_err_code parse_blob(TALLOC_CTX *ctx, DATA_BLOB *blob,
 {
        struct ndr_pull *ndr = NULL;
        enum ndr_err_code err;
-       int ndr_flags = NDR_SCALARS | NDR_BUFFERS;
+       ndr_flags_type ndr_flags = NDR_SCALARS | NDR_BUFFERS;
        uint32_t status = 0;
 
        ndr = ndr_pull_init_blob(blob, ctx);
@@ -1943,7 +1943,7 @@ static enum ndr_err_code insert_header_and_checksum(TALLOC_CTX *ctx,
                struct wsp_header *header)
 {
        enum ndr_err_code err;
-       int ndr_flags = NDR_SCALARS | NDR_BUFFERS;
+       ndr_flags_type ndr_flags = NDR_SCALARS | NDR_BUFFERS;
        struct ndr_push *header_ndr = ndr_push_init_ctx(ctx);
 
        if (header_ndr == NULL) {
@@ -1976,7 +1976,7 @@ NTSTATUS wsp_request_response(TALLOC_CTX* ctx,
        struct rpc_pipe_client *p = wsp_ctx->rpccli;
        NTSTATUS status = NT_STATUS_OK;
 
-       int ndr_flags = NDR_SCALARS | NDR_BUFFERS;
+       ndr_flags_type ndr_flags = NDR_SCALARS | NDR_BUFFERS;
        struct ndr_push* push_ndr = NULL;
 
        enum ndr_err_code err;
index cf54d998891b6aabf8ca841f3c34eba9dffcbce0..7835bd32123967d056eff5929d0bf042e5284be2 100644 (file)
@@ -287,7 +287,7 @@ static bool wbint_bh_ref_alloc(struct dcerpc_binding_handle *h)
 }
 
 static void wbint_bh_do_ndr_print(struct dcerpc_binding_handle *h,
-                                 int ndr_flags,
+                                 ndr_flags_type ndr_flags,
                                  const void *_struct_ptr,
                                  const struct ndr_interface_call *call)
 {
index eb5ff46e97f9eee1db65ae8aea7e06ed4bf719d9..6d859f77dd4ec71495c01511f97e4248ea2e0b3f 100644 (file)
@@ -1408,7 +1408,7 @@ static bool irpc_bh_ref_alloc(struct dcerpc_binding_handle *h)
 }
 
 static void irpc_bh_do_ndr_print(struct dcerpc_binding_handle *h,
-                                int ndr_flags,
+                                ndr_flags_type ndr_flags,
                                 const void *_struct_ptr,
                                 const struct ndr_interface_call *call)
 {
index baf6df6e498b0438805501d58b99277c1207873f..802759c72b2022bee6782755c533433de3a3e52f 100644 (file)
@@ -436,7 +436,7 @@ static bool dcerpc_bh_use_ndr64(struct dcerpc_binding_handle *h)
 }
 
 static void dcerpc_bh_do_ndr_print(struct dcerpc_binding_handle *h,
-                                  int ndr_flags,
+                                  ndr_flags_type ndr_flags,
                                   const void *_struct_ptr,
                                   const struct ndr_interface_call *call)
 {
index cc14e3a668a60cd8e2e5cfc62963523e72de3223..0faef1ab643668fab9b583f91ec5968222e90fae 100644 (file)
@@ -33,12 +33,12 @@ struct ndr_pull_test_data {
        ndr_push_flags_fn_t push_fn;
        ndr_print_fn_t print_fn;
        ndr_print_function_t print_function;
-       int ndr_flags;
+       ndr_flags_type ndr_flags;
        libndr_flags flags;
        enum ndr_err_code ndr_err;
 };
 
-static enum ndr_err_code torture_ndr_push_struct_blob_flags(DATA_BLOB *blob, TALLOC_CTX *mem_ctx, uint32_t flags, libndr_flags ndr_flags, const void *p, ndr_push_flags_fn_t fn)
+static enum ndr_err_code torture_ndr_push_struct_blob_flags(DATA_BLOB *blob, TALLOC_CTX *mem_ctx, ndr_flags_type flags, libndr_flags ndr_flags, const void *p, ndr_push_flags_fn_t fn)
 {
        struct ndr_push *ndr;
        ndr = ndr_push_init_ctx(mem_ctx);
@@ -58,13 +58,13 @@ static enum ndr_err_code torture_ndr_push_struct_blob_flags(DATA_BLOB *blob, TAL
 static bool torture_ndrdump(struct torture_context *tctx,
                            struct ndr_pull *ndr,
                            const struct ndr_pull_test_data *data,
-                           uint32_t flags,
+                           ndr_flags_type flags,
                            void *ds,
                            const char *name)
 {
        struct ndr_print *ndr_print;
        const char *name_raw;
-       uint32_t ndr_flags = data->ndr_flags | flags;
+       ndr_flags_type ndr_flags = data->ndr_flags | flags;
 
        ndr_print = talloc_zero(tctx, struct ndr_print);
        torture_assert(tctx, ndr_print, "out of memory");
@@ -155,7 +155,7 @@ _PUBLIC_ struct torture_test *_torture_suite_add_ndr_pullpush_test(
        const char *db_name,
        DATA_BLOB db,
        size_t struct_size,
-       int ndr_flags,
+       ndr_flags_type ndr_flags,
        libndr_flags flags,
        const char *check_fn_name,
        bool (*check_fn) (struct torture_context *ctx, void *data))
@@ -344,7 +344,7 @@ _PUBLIC_ struct torture_test *_torture_suite_add_ndr_pull_invalid_data_test(
        const char *db_name,
        DATA_BLOB db,
        size_t struct_size,
-       int ndr_flags,
+       ndr_flags_type ndr_flags,
        libndr_flags flags,
        enum ndr_err_code ndr_err)
 {
index 805f51711c9502f84ecc34f44c198b3070f6558f..82ccc69e94dca77f3eb13be38430916ee1d18aaa 100644 (file)
@@ -34,7 +34,7 @@ _PUBLIC_ struct torture_test *_torture_suite_add_ndr_pullpush_test(
                                        const char *db_name,
                                        DATA_BLOB db,
                                        size_t struct_size,
-                                       int ndr_flags,
+                                       ndr_flags_type ndr_flags,
                                        libndr_flags flags,
                                        const char *check_fn_name,
                                        bool (*check_fn) (struct torture_context *, void *data));
@@ -60,7 +60,7 @@ _PUBLIC_ struct torture_test *_torture_suite_add_ndr_pull_invalid_data_test(
        const char *db_name,
        DATA_BLOB db,
        size_t struct_size,
-       int ndr_flags,
+       ndr_flags_type ndr_flags,
        libndr_flags flags,
        enum ndr_err_code ndr_err);
 
index c12976b38cc12a9e72579fb63eae76bd31436e92..3a7ee64827862e822a62cd6407594bc62490793e 100644 (file)
@@ -953,7 +953,7 @@ static bool test_setup_binding_handle(struct torture_context *tctx,
 
 static enum ndr_err_code ndr_push_inout_blob(DATA_BLOB *blob,
                                             TALLOC_CTX *mem_ctx,
-                                            int flags,
+                                            ndr_flags_type flags,
                                             const void *p,
                                             ndr_push_flags_fn_t fn)
 {