diff options
author | Andrew Tridgell <tridge@samba.org> | 2005-02-10 05:09:35 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:09:38 -0500 |
commit | e82aad1ce39a6b7a2e51b9e2cb494d74ec70e158 (patch) | |
tree | b66f04c223e55e435b6ba56f4f05d2bf03132a12 | |
parent | e3aae721a7d5c8130448d67feb3a9200e14393ac (diff) | |
download | samba-e82aad1ce39a6b7a2e51b9e2cb494d74ec70e158.tar.gz |
r5298: - got rid of pstring.h from includes.h. This at least makes it a bit
less likely that anyone will use pstring for new code
- got rid of winbind_client.h from includes.h. This one triggered a
huge change, as winbind_client.h was including system/filesys.h and
defining the old uint32 and uint16 types, as well as its own
pstring and fstring.
(This used to be commit 9db6c79e902ec538108d6b7d3324039aabe1704f)
137 files changed, 239 insertions, 114 deletions
diff --git a/source4/auth/auth_developer.c b/source4/auth/auth_developer.c index 6bb015ad351..fe0eb12cded 100644 --- a/source4/auth/auth_developer.c +++ b/source4/auth/auth_developer.c @@ -24,6 +24,7 @@ #include "auth/auth.h" #include "librpc/gen_ndr/ndr_samr.h" #include "librpc/gen_ndr/ndr_security.h" +#include "pstring.h" /** * Return an error based on username diff --git a/source4/auth/auth_sam.c b/source4/auth/auth_sam.c index 44a8b19cae1..2a2a437ded0 100644 --- a/source4/auth/auth_sam.c +++ b/source4/auth/auth_sam.c @@ -25,6 +25,7 @@ #include "system/time.h" #include "auth/auth.h" #include "lib/ldb/include/ldb.h" +#include "pstring.h" /**************************************************************************** Do a specific test for an smb password being correct, given a smb_password and diff --git a/source4/auth/auth_winbind.c b/source4/auth/auth_winbind.c index 2ded310ebc3..8a6a5a720bf 100644 --- a/source4/auth/auth_winbind.c +++ b/source4/auth/auth_winbind.c @@ -25,6 +25,7 @@ #include "includes.h" #include "librpc/gen_ndr/ndr_netlogon.h" #include "auth/auth.h" +#include "nsswitch/winbind_client.h" static NTSTATUS get_info3_from_ndr(TALLOC_CTX *mem_ctx, struct winbindd_response *response, struct netr_SamInfo3 *info3) { diff --git a/source4/build/pidl/server.pm b/source4/build/pidl/server.pm index e080bf56547..46dada7c7f9 100644 --- a/source4/build/pidl/server.pm +++ b/source4/build/pidl/server.pm @@ -103,7 +103,7 @@ static void $name\__op_unbind(struct dcesrv_connection_context *context, const s static NTSTATUS $name\__op_ndr_pull(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, struct ndr_pull *pull, void **r) { NTSTATUS status; - uint16 opnum = dce_call->pkt.u.request.opnum; + uint16_t opnum = dce_call->pkt.u.request.opnum; dce_call->fault_code = 0; @@ -129,7 +129,7 @@ static NTSTATUS $name\__op_ndr_pull(struct dcesrv_call_state *dce_call, TALLOC_C static NTSTATUS $name\__op_dispatch(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, void *r) { - uint16 opnum = dce_call->pkt.u.request.opnum; + uint16_t opnum = dce_call->pkt.u.request.opnum; switch (opnum) { "; @@ -152,7 +152,7 @@ pidl " static NTSTATUS $name\__op_reply(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, void *r) { - uint16 opnum = dce_call->pkt.u.request.opnum; + uint16_t opnum = dce_call->pkt.u.request.opnum; switch (opnum) { "; @@ -176,7 +176,7 @@ pidl " static NTSTATUS $name\__op_ndr_push(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, struct ndr_push *push, void *r) { NTSTATUS status; - uint16 opnum = dce_call->pkt.u.request.opnum; + uint16_t opnum = dce_call->pkt.u.request.opnum; status = dcerpc_table_$name.calls[opnum].ndr_push(push, NDR_OUT, r); if (!NT_STATUS_IS_OK(status)) { @@ -229,7 +229,7 @@ static NTSTATUS $name\__op_init_server(struct dcesrv_context *dce_ctx, const str return NT_STATUS_OK; } -static BOOL $name\__op_interface_by_uuid(struct dcesrv_interface *iface, const char *uuid, uint32 if_version) +static BOOL $name\__op_interface_by_uuid(struct dcesrv_interface *iface, const char *uuid, uint32_t if_version) { if ($name\_interface.if_version == if_version && strcmp($name\_interface.uuid, uuid)==0) { diff --git a/source4/build/pidl/stub.pm b/source4/build/pidl/stub.pm index a9c938df63b..53be35b2160 100644 --- a/source4/build/pidl/stub.pm +++ b/source4/build/pidl/stub.pm @@ -107,7 +107,7 @@ static void $name\__op_unbind(struct dcesrv_connection_context *context, const s static NTSTATUS $name\__op_ndr_pull(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, struct ndr_pull *pull, void **r) { NTSTATUS status; - uint16 opnum = dce_call->pkt.u.request.opnum; + uint16_t opnum = dce_call->pkt.u.request.opnum; dce_call->fault_code = 0; @@ -133,7 +133,7 @@ static NTSTATUS $name\__op_ndr_pull(struct dcesrv_call_state *dce_call, TALLOC_C static NTSTATUS $name\__op_dispatch(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, void *r) { - uint16 opnum = dce_call->pkt.u.request.opnum; + uint16_t opnum = dce_call->pkt.u.request.opnum; struct GUID ipid = dce_call->pkt.u.request.object.object; struct dcom_interface_p *iface = dcom_get_local_iface_p(&ipid); const struct dcom_$name\_vtable *vtable = iface->vtable; @@ -159,7 +159,7 @@ pidl " static NTSTATUS $name\__op_reply(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, void *r) { - uint16 opnum = dce_call->pkt.u.request.opnum; + uint16_t opnum = dce_call->pkt.u.request.opnum; switch (opnum) { "; @@ -183,7 +183,7 @@ pidl " static NTSTATUS $name\__op_ndr_push(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, struct ndr_push *push, void *r) { NTSTATUS status; - uint16 opnum = dce_call->pkt.u.request.opnum; + uint16_t opnum = dce_call->pkt.u.request.opnum; status = dcerpc_table_$name.calls[opnum].ndr_push(push, NDR_OUT, r); if (!NT_STATUS_IS_OK(status)) { @@ -236,7 +236,7 @@ static NTSTATUS $name\__op_init_server(struct dcesrv_context *dce_ctx, const str return NT_STATUS_OK; } -static BOOL $name\__op_interface_by_uuid(struct dcesrv_interface *iface, const char *uuid, uint32 if_version) +static BOOL $name\__op_interface_by_uuid(struct dcesrv_interface *iface, const char *uuid, uint32_t if_version) { if (dcerpc_table_$name.if_version == if_version && strcmp(dcerpc_table_$name.uuid, uuid)==0) { diff --git a/source4/dsdb/samdb/samdb.c b/source4/dsdb/samdb/samdb.c index a4f200c33f5..1af80c12bdd 100644 --- a/source4/dsdb/samdb/samdb.c +++ b/source4/dsdb/samdb/samdb.c @@ -24,6 +24,7 @@ #include "librpc/gen_ndr/ndr_netlogon.h" #include "lib/ldb/include/ldb.h" #include "system/time.h" +#include "system/filesys.h" /* connect to the SAM database @@ -551,7 +552,7 @@ struct samr_LogonHours samdb_result_logon_hours(TALLOC_CTX *mem_ctx, struct ldb_ const int units_per_week = 168; const struct ldb_val *val = ldb_msg_find_ldb_val(msg, attr); ZERO_STRUCT(hours); - hours.bits = talloc_array(mem_ctx, uint8, units_per_week); + hours.bits = talloc_array(mem_ctx, uint8_t, units_per_week); if (!hours.bits) { return hours; } diff --git a/source4/dynconfig.c b/source4/dynconfig.c index cbe9ea49cea..c76d448b8cd 100644 --- a/source4/dynconfig.c +++ b/source4/dynconfig.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "pstring.h" /** * @file dynconfig.c diff --git a/source4/include/dynconfig.h b/source4/include/dynconfig.h index 48e02c078a3..a95e67a90db 100644 --- a/source4/include/dynconfig.h +++ b/source4/include/dynconfig.h @@ -25,6 +25,8 @@ * @brief Exported global configurations. **/ +#include "pstring.h" + extern char const *dyn_SBINDIR, *dyn_BINDIR; diff --git a/source4/include/includes.h b/source4/include/includes.h index cef5e982c7e..890491f8844 100644 --- a/source4/include/includes.h +++ b/source4/include/includes.h @@ -120,7 +120,6 @@ extern int errno; #include "debug.h" #include "doserr.h" #include "enums.h" -#include "pstring.h" #include "smb_macros.h" #include "smb.h" #include "lib/socket/socket.h" @@ -137,7 +136,6 @@ extern int errno; #include "smb_interfaces.h" #include "ntvfs/ntvfs.h" #include "cli_context.h" -#include "nsswitch/winbind_client.h" #include "ads.h" #define malloc_p(type) (type *)malloc(sizeof(type)) diff --git a/source4/include/pstring.h b/source4/include/pstring.h index 5bd03ec0d8f..36838496865 100644 --- a/source4/include/pstring.h +++ b/source4/include/pstring.h @@ -25,6 +25,8 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ +#ifndef _PSTRING + #define PSTRING_LEN 1024 #define FSTRING_LEN 256 @@ -32,3 +34,4 @@ typedef char pstring[PSTRING_LEN]; typedef char fstring[FSTRING_LEN]; #define _PSTRING +#endif diff --git a/source4/include/rap.h b/source4/include/rap.h index 0477192d9e7..c831f6f0079 100644 --- a/source4/include/rap.h +++ b/source4/include/rap.h @@ -286,7 +286,7 @@ struct rap_shareenum_info_0 { struct rap_shareenum_info_1 { char name[13]; char pad; - uint16 type; + uint16_t type; char *comment; }; @@ -297,15 +297,15 @@ union rap_shareenum_info { struct rap_NetShareEnum { struct { - uint16 level; - uint16 bufsize; + uint16_t level; + uint16_t bufsize; } in; struct { - uint16 status; - uint16 convert; - uint16 count; - uint16 available; + uint16_t status; + uint16_t convert; + uint16_t count; + uint16_t available; union rap_shareenum_info *info; } out; }; @@ -329,17 +329,17 @@ union rap_server_info { struct rap_NetServerEnum2 { struct { - uint16 level; - uint16 bufsize; - uint32 servertype; + uint16_t level; + uint16_t bufsize; + uint32_t servertype; const char *domain; } in; struct { - uint16 status; - uint16 convert; - uint16 count; - uint16 available; + uint16_t status; + uint16_t convert; + uint16_t count; + uint16_t available; union rap_server_info *info; } out; }; diff --git a/source4/intl/lang_tdb.c b/source4/intl/lang_tdb.c index 660323682db..de08c82ce4e 100644 --- a/source4/intl/lang_tdb.c +++ b/source4/intl/lang_tdb.c @@ -21,6 +21,8 @@ #include "includes.h" #include "lib/tdb/include/tdbutil.h" #include "system/time.h" +#include "system/filesys.h" +#include "pstring.h" static TDB_CONTEXT *tdb; diff --git a/source4/lib/charcnv.c b/source4/lib/charcnv.c index 4cf5d004657..ea0fcd8d32f 100644 --- a/source4/lib/charcnv.c +++ b/source4/lib/charcnv.c @@ -22,6 +22,7 @@ */ #include "includes.h" #include "system/iconv.h" +#include "pstring.h" /** * @file diff --git a/source4/lib/cmdline/popt_common.h b/source4/lib/cmdline/popt_common.h index 06560d2be58..d6ae43d0837 100644 --- a/source4/lib/cmdline/popt_common.h +++ b/source4/lib/cmdline/popt_common.h @@ -22,6 +22,7 @@ #define _POPT_COMMON_H #include "popt.h" +#include "pstring.h" /* Common popt structures */ extern struct poptOption popt_common_samba[]; diff --git a/source4/lib/cmdline/readline.c b/source4/lib/cmdline/readline.c index 8836759f70b..4970638d41f 100644 --- a/source4/lib/cmdline/readline.c +++ b/source4/lib/cmdline/readline.c @@ -20,6 +20,7 @@ */ #include "includes.h" +#include "pstring.h" #include <unistd.h> diff --git a/source4/lib/dcom/common/main.c b/source4/lib/dcom/common/main.c index 01906501f1f..a8324606f10 100644 --- a/source4/lib/dcom/common/main.c +++ b/source4/lib/dcom/common/main.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "dlinklist.h" #include "librpc/gen_ndr/ndr_epmapper.h" #include "librpc/gen_ndr/ndr_remact.h" @@ -145,7 +146,7 @@ WERROR dcom_ping(struct dcom_context *ctx) static WERROR dcom_create_object_remote(struct dcom_context *ctx, struct GUID *clsid, const char *server, int num_ifaces, struct GUID *iid, struct dcom_interface_p ***ip, WERROR *results) { - uint16 protseq[] = DCOM_NEGOTIATED_PROTOCOLS; + uint16_t protseq[] = DCOM_NEGOTIATED_PROTOCOLS; struct dcerpc_pipe *p; struct dcom_object_exporter *m; NTSTATUS status; @@ -268,7 +269,7 @@ WERROR dcom_get_class_object_remote(struct dcom_context *ctx, struct GUID *clsid struct DUALSTRINGARRAY dualstring; NTSTATUS status; struct pMInterfacePointer pm; - uint16 protseq[] = DCOM_NEGOTIATED_PROTOCOLS; + uint16_t protseq[] = DCOM_NEGOTIATED_PROTOCOLS; status = dcom_connect_host(ctx, &p, server); if (NT_STATUS_IS_ERR(status)) { @@ -498,7 +499,7 @@ NTSTATUS dcom_ifacep_from_OBJREF(struct dcom_context *ctx, struct dcom_interface if (!m) { struct dcerpc_pipe *po; struct ResolveOxid r; - uint16 protseq[] = DCOM_NEGOTIATED_PROTOCOLS; + uint16_t protseq[] = DCOM_NEGOTIATED_PROTOCOLS; DEBUG(3, ("No binding data present yet, resolving OXID %llu\n", p->ox->oxid)); diff --git a/source4/lib/debug.c b/source4/lib/debug.c index f1e9cec38e8..ab012a98aa2 100644 --- a/source4/lib/debug.c +++ b/source4/lib/debug.c @@ -20,6 +20,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "dynconfig.h" /* this global variable determines what messages are printed */ diff --git a/source4/lib/events/events.c b/source4/lib/events/events.c index 140e3ff0671..34606273995 100644 --- a/source4/lib/events/events.c +++ b/source4/lib/events/events.c @@ -57,6 +57,7 @@ #include "includes.h" #include "system/time.h" #include "system/select.h" +#include "system/filesys.h" #include "dlinklist.h" #include "lib/events/events.h" diff --git a/source4/lib/fault.c b/source4/lib/fault.c index d90281f950c..9f1e3f44bc0 100644 --- a/source4/lib/fault.c +++ b/source4/lib/fault.c @@ -21,6 +21,7 @@ #include "includes.h" #include "version.h" #include "system/wait.h" +#include "system/filesys.h" static void (*cont_fn)(void *); diff --git a/source4/lib/gencache.c b/source4/lib/gencache.c index 8688683e8d2..1a6159942d8 100644 --- a/source4/lib/gencache.c +++ b/source4/lib/gencache.c @@ -24,6 +24,7 @@ #include "includes.h" #include "lib/tdb/include/tdbutil.h" #include "system/time.h" +#include "system/filesys.h" #undef DBGC_CLASS #define DBGC_CLASS DBGC_TDB diff --git a/source4/lib/genrand.c b/source4/lib/genrand.c index 0f1d02b7101..e3df9f9d909 100644 --- a/source4/lib/genrand.c +++ b/source4/lib/genrand.c @@ -22,10 +22,11 @@ #include "includes.h" #include "system/iconv.h" +#include "system/filesys.h" #include "lib/crypto/crypto.h" static unsigned char hash[258]; -static uint32 counter; +static uint32_t counter; static BOOL done_reseed = False; static void (*reseed_callback)(int *newseed); @@ -147,7 +148,7 @@ static void do_filehash(const char *fname, unsigned char *the_hash) static int do_reseed(BOOL use_fd, int fd) { unsigned char seed_inbuf[40]; - uint32 v1, v2; struct timeval tval; pid_t mypid; + uint32_t v1, v2; struct timeval tval; pid_t mypid; int reseed_data = 0; if (use_fd) { diff --git a/source4/lib/iconv.c b/source4/lib/iconv.c index 181834d66aa..df590444e58 100644 --- a/source4/lib/iconv.c +++ b/source4/lib/iconv.c @@ -22,6 +22,7 @@ #include "includes.h" #include "dlinklist.h" #include "system/iconv.h" +#include "system/filesys.h" /** diff --git a/source4/lib/ldb/ldb_tdb/ldb_tdb.h b/source4/lib/ldb/ldb_tdb/ldb_tdb.h index 0c644ffe5e4..4c2fc52f7c8 100644 --- a/source4/lib/ldb/ldb_tdb/ldb_tdb.h +++ b/source4/lib/ldb/ldb_tdb/ldb_tdb.h @@ -1,5 +1,6 @@ #ifdef _SAMBA_BUILD_ +#include "system/filesys.h" #include "lib/tdb/include/tdb.h" #else #include "tdb.h" diff --git a/source4/lib/ldb/tools/ldbadd.c b/source4/lib/ldb/tools/ldbadd.c index d95036497ad..927debc65e2 100644 --- a/source4/lib/ldb/tools/ldbadd.c +++ b/source4/lib/ldb/tools/ldbadd.c @@ -36,6 +36,10 @@ #include "ldb/include/ldb.h" #include "ldb/include/ldb_private.h" +#ifdef _SAMBA_BUILD_ +#include "system/filesys.h" +#endif + static int failures; static void usage(void) diff --git a/source4/lib/ldb/tools/ldbdel.c b/source4/lib/ldb/tools/ldbdel.c index 29d3b397304..2241a0b8230 100644 --- a/source4/lib/ldb/tools/ldbdel.c +++ b/source4/lib/ldb/tools/ldbdel.c @@ -36,6 +36,10 @@ #include "ldb/include/ldb.h" #include "ldb/include/ldb_private.h" +#ifdef _SAMBA_BUILD_ +#include "system/filesys.h" +#endif + static int ldb_delete_recursive(struct ldb_context *ldb, const char *dn) { int ret, i, total=0; diff --git a/source4/lib/ldb/tools/ldbedit.c b/source4/lib/ldb/tools/ldbedit.c index 4c38ea6803b..20cb7da810b 100644 --- a/source4/lib/ldb/tools/ldbedit.c +++ b/source4/lib/ldb/tools/ldbedit.c @@ -36,6 +36,10 @@ #include "ldb/include/ldb.h" #include "ldb/include/ldb_private.h" +#ifdef _SAMBA_BUILD_ +#include "system/filesys.h" +#endif + static int verbose; /* diff --git a/source4/lib/ldb/tools/ldbmodify.c b/source4/lib/ldb/tools/ldbmodify.c index 3bdb946897e..97dec1050e7 100644 --- a/source4/lib/ldb/tools/ldbmodify.c +++ b/source4/lib/ldb/tools/ldbmodify.c @@ -36,6 +36,10 @@ #include "ldb/include/ldb.h" #include "ldb/include/ldb_private.h" +#ifdef _SAMBA_BUILD_ +#include "system/filesys.h" +#endif + static int failures; static void usage(void) diff --git a/source4/lib/ldb/tools/ldbrename.c b/source4/lib/ldb/tools/ldbrename.c index 3ee001cf23f..ba870b0a457 100644 --- a/source4/lib/ldb/tools/ldbrename.c +++ b/source4/lib/ldb/tools/ldbrename.c @@ -38,6 +38,10 @@ #include "ldb/include/ldb.h" #include "ldb/include/ldb_private.h" +#ifdef _SAMBA_BUILD_ +#include "system/filesys.h" +#endif + static void usage(void) { printf("Usage: ldbrename [<options>] <olddn> <newdn>\n"); diff --git a/source4/lib/ldb/tools/ldbsearch.c b/source4/lib/ldb/tools/ldbsearch.c index 5e0246d7a93..f764b285579 100644 --- a/source4/lib/ldb/tools/ldbsearch.c +++ b/source4/lib/ldb/tools/ldbsearch.c @@ -36,6 +36,10 @@ #include "ldb/include/ldb.h" #include "ldb/include/ldb_private.h" +#ifdef _SAMBA_BUILD_ +#include "system/filesys.h" +#endif + static void usage(void) { printf("Usage: ldbsearch <options> <expression> <attrs...>\n"); diff --git a/source4/lib/ldb/tools/ldbtest.c b/source4/lib/ldb/tools/ldbtest.c index 01fa1b8ed7a..67630d44583 100644 --- a/source4/lib/ldb/tools/ldbtest.c +++ b/source4/lib/ldb/tools/ldbtest.c @@ -36,6 +36,10 @@ #include "ldb/include/ldb.h" #include "ldb/include/ldb_private.h" +#ifdef _SAMBA_BUILD_ +#include "system/filesys.h" +#endif + static const char *ldb_url; static const char *base_dn = "ou=Ldb Test,ou=People,o=University of Michigan,c=US"; diff --git a/source4/lib/messaging/messaging.c b/source4/lib/messaging/messaging.c index aab13ba8af9..df0216617d0 100644 --- a/source4/lib/messaging/messaging.c +++ b/source4/lib/messaging/messaging.c @@ -22,6 +22,7 @@ #include "includes.h" #include "lib/events/events.h" +#include "system/filesys.h" #include "system/time.h" #include "messages.h" #include "dlinklist.h" diff --git a/source4/lib/pidfile.c b/source4/lib/pidfile.c index f8041a20050..ff05c0606e4 100644 --- a/source4/lib/pidfile.c +++ b/source4/lib/pidfile.c @@ -21,6 +21,8 @@ */ #include "includes.h" +#include "pstring.h" +#include "system/filesys.h" #ifndef O_NONBLOCK #define O_NONBLOCK diff --git a/source4/lib/registry/reg_backend_dir.c b/source4/lib/registry/reg_backend_dir.c index bac0f43c20d..68f02d17459 100644 --- a/source4/lib/registry/reg_backend_dir.c +++ b/source4/lib/registry/reg_backend_dir.c @@ -21,6 +21,7 @@ #include "includes.h" #include "registry.h" #include "system/dir.h" +#include "system/filesys.h" static WERROR reg_dir_add_key(TALLOC_CTX *mem_ctx, struct registry_key *parent, const char *name, uint32_t access_mask, struct security_descriptor *desc, struct registry_key **result) { diff --git a/source4/lib/registry/reg_backend_ldb.c b/source4/lib/registry/reg_backend_ldb.c index 930ea9642e0..c7b7bf587f5 100644 --- a/source4/lib/registry/reg_backend_ldb.c +++ b/source4/lib/registry/reg_backend_ldb.c @@ -36,7 +36,7 @@ static int ldb_close_hive (void *_hive) return 0; } -static void reg_ldb_unpack_value(TALLOC_CTX *mem_ctx, struct ldb_message *msg, char **name, uint32 *type, void **data, int *len) +static void reg_ldb_unpack_value(TALLOC_CTX *mem_ctx, struct ldb_message *msg, char **name, uint32_t *type, void **data, int *len) { const struct ldb_val *val; *name = talloc_strdup(mem_ctx, ldb_msg_find_string(msg, "value", NULL)); @@ -52,7 +52,7 @@ static void reg_ldb_unpack_value(TALLOC_CTX *mem_ctx, struct ldb_message *msg, c case REG_DWORD_LE: *len = 4; - *data = talloc(mem_ctx, uint32); + *data = talloc(mem_ctx, uint32_t); SIVAL(*data, 0, strtol(val->data, NULL, 0)); break; @@ -63,7 +63,7 @@ static void reg_ldb_unpack_value(TALLOC_CTX *mem_ctx, struct ldb_message *msg, c } } -static struct ldb_message *reg_ldb_pack_value(struct ldb_context *ctx, TALLOC_CTX *mem_ctx, const char *name, uint32 type, void *data, int len) +static struct ldb_message *reg_ldb_pack_value(struct ldb_context *ctx, TALLOC_CTX *mem_ctx, const char *name, uint32_t type, void *data, int len) { struct ldb_val val; struct ldb_message *msg = talloc_zero(mem_ctx, struct ldb_message); @@ -322,7 +322,7 @@ static WERROR ldb_del_value (struct registry_key *key, const char *child) return WERR_OK; } -static WERROR ldb_set_value (struct registry_key *parent, const char *name, uint32 type, void *data, int len) +static WERROR ldb_set_value (struct registry_key *parent, const char *name, uint32_t type, void *data, int len) { struct ldb_context *ctx = parent->hive->backend_data; struct ldb_message *msg; diff --git a/source4/lib/registry/reg_backend_rpc.c b/source4/lib/registry/reg_backend_rpc.c index d2809f644a2..23024165545 100644 --- a/source4/lib/registry/reg_backend_rpc.c +++ b/source4/lib/registry/reg_backend_rpc.c @@ -78,7 +78,7 @@ struct rpc_key_data { }; struct { - uint32 hkey; + uint32_t hkey; WERROR (*open) (struct dcerpc_pipe *p, TALLOC_CTX *, struct policy_handle *h); } known_hives[] = { { HKEY_LOCAL_MACHINE, open_HKLM }, @@ -93,7 +93,7 @@ struct { static WERROR rpc_query_key(struct registry_key *k); -static WERROR rpc_get_predefined_key (struct registry_context *ctx, uint32 hkey_type, struct registry_key **k) +static WERROR rpc_get_predefined_key (struct registry_context *ctx, uint32_t hkey_type, struct registry_key **k) { int n; struct registry_hive *h; @@ -185,7 +185,7 @@ static WERROR rpc_get_value_by_index(TALLOC_CTX *mem_ctx, struct registry_key *p struct rpc_key_data *mykeydata = parent->backend_data; WERROR error; struct winreg_EnumValue r; - uint32 type, len1, zero = 0; + uint32_t type, len1, zero = 0; NTSTATUS status; uint8_t buf8; uint16_t buf16; diff --git a/source4/lib/registry/reg_samba.c b/source4/lib/registry/reg_samba.c index a81b9e5a425..7188109daa8 100644 --- a/source4/lib/registry/reg_samba.c +++ b/source4/lib/registry/reg_samba.c @@ -23,7 +23,7 @@ #undef DBGC_CLASS #define DBGC_CLASS DBGC_REGISTRY -static WERROR reg_samba_get_predef (struct registry_context *ctx, uint32 hkey, struct registry_key **k) +static WERROR reg_samba_get_predef (struct registry_context *ctx, uint32_t hkey, struct registry_key **k) { WERROR error; const char *conf; diff --git a/source4/lib/select.c b/source4/lib/select.c index 5d7e4a0ad2a..bed02304cc8 100644 --- a/source4/lib/select.c +++ b/source4/lib/select.c @@ -20,6 +20,7 @@ */ #include "includes.h" +#include "system/filesys.h" /* This is here because it allows us to avoid a nasty race in signal handling. We need to guarantee that when we get a signal we get out of a select immediately diff --git a/source4/lib/socket/socket.c b/source4/lib/socket/socket.c index 97176ea1504..109a7cadc01 100644 --- a/source4/lib/socket/socket.c +++ b/source4/lib/socket/socket.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "system/filesys.h" /* auto-close sockets on free diff --git a/source4/lib/socket/socket_ipv4.c b/source4/lib/socket/socket_ipv4.c index 09a4b4a73a8..2a212fbc944 100644 --- a/source4/lib/socket/socket_ipv4.c +++ b/source4/lib/socket/socket_ipv4.c @@ -23,6 +23,7 @@ #include "includes.h" #include "system/network.h" +#include "system/filesys.h" static NTSTATUS ipv4_init(struct socket_context *sock) { diff --git a/source4/lib/socket/socket_ipv6.c b/source4/lib/socket/socket_ipv6.c index f5cd756259a..d7241d9b383 100644 --- a/source4/lib/socket/socket_ipv6.c +++ b/source4/lib/socket/socket_ipv6.c @@ -21,6 +21,7 @@ #include "includes.h" #include "system/network.h" +#include "system/filesys.h" static struct in6_addr interpret_addr6(const char *name) { diff --git a/source4/lib/socket/socket_unix.c b/source4/lib/socket/socket_unix.c index e23aa0d97e9..2bcce0eb118 100644 --- a/source4/lib/socket/socket_unix.c +++ b/source4/lib/socket/socket_unix.c @@ -23,6 +23,7 @@ #include "includes.h" #include "system/network.h" +#include "system/filesys.h" diff --git a/source4/lib/system.c b/source4/lib/system.c index b23529f5fe0..eb3799c7cad 100644 --- a/source4/lib/system.c +++ b/source4/lib/system.c @@ -23,6 +23,7 @@ #include "system/network.h" #include "system/wait.h" #include "system/filesys.h" +#include "pstring.h" /* The idea is that this file will eventually have wrappers around all diff --git a/source4/lib/tdb/common/spinlock.c b/source4/lib/tdb/common/spinlock.c index 001f0c3bc11..232cd8dfc6a 100644 --- a/source4/lib/tdb/common/spinlock.c +++ b/source4/lib/tdb/common/spinlock.c @@ -43,6 +43,7 @@ #else #include "includes.h" #include "lib/tdb/include/tdb.h" +#include "system/filesys.h" #endif #ifdef USE_SPINLOCKS diff --git a/source4/lib/tdb/common/tdbutil.c b/source4/lib/tdb/common/tdbutil.c index 02a1d66cbe9..e3c56410544 100644 --- a/source4/lib/tdb/common/tdbutil.c +++ b/source4/lib/tdb/common/tdbutil.c @@ -22,7 +22,9 @@ #include "lib/tdb/include/tdbutil.h" #include "system/glob.h" #include "system/wait.h" +#include "system/filesys.h" #include "dlinklist.h" +#include "pstring.h" /* these are little tdb utility functions that are meant to make dealing with a tdb database a little less cumbersome in Samba */ diff --git a/source4/lib/tdb/tools/tdbdump.c b/source4/lib/tdb/tools/tdbdump.c index 8aa573ca9b6..774093dbc0c 100644 --- a/source4/lib/tdb/tools/tdbdump.c +++ b/source4/lib/tdb/tools/tdbdump.c @@ -39,6 +39,7 @@ #include "includes.h" #include "lib/tdb/include/tdb.h" #include "system/iconv.h" +#include "system/filesys.h" #endif diff --git a/source4/lib/tdb/tools/tdbtorture.c b/source4/lib/tdb/tools/tdbtorture.c index 63b3b0d3818..7e8e77952c1 100644 --- a/source4/lib/tdb/tools/tdbtorture.c +++ b/source4/lib/tdb/tools/tdbtorture.c @@ -24,6 +24,7 @@ #include "lib/tdb/include/tdb.h" #include "system/time.h" #include "system/wait.h" +#include "system/filesys.h" #endif diff --git a/source4/lib/unix_privs.c b/source4/lib/unix_privs.c index a57f4359d3b..b59657b7d59 100644 --- a/source4/lib/unix_privs.c +++ b/source4/lib/unix_privs.c @@ -22,6 +22,7 @@ #include "includes.h" #include "system/passwd.h" +#include "system/filesys.h" /* there are times when smbd needs to temporarily gain root privileges diff --git a/source4/lib/username.c b/source4/lib/username.c index 1c8e5aa2bb8..55965a7980b 100644 --- a/source4/lib/username.c +++ b/source4/lib/username.c @@ -20,6 +20,7 @@ */ #include "includes.h" +#include "pstring.h" /***************************************************************** Splits passed user or group name to domain and user/group name parts diff --git a/source4/lib/util.c b/source4/lib/util.c index dba2dbfe879..af41a20aa57 100644 --- a/source4/lib/util.c +++ b/source4/lib/util.c @@ -26,6 +26,7 @@ #include "dynconfig.h" #include "system/network.h" #include "system/iconv.h" +#include "system/filesys.h" /**************************************************************************n Find a suitable temporary directory. The result should be copied immediately diff --git a/source4/lib/util_file.c b/source4/lib/util_file.c index 2b2fe2b2afc..6d234b571c7 100644 --- a/source4/lib/util_file.c +++ b/source4/lib/util_file.c @@ -20,6 +20,7 @@ #include "includes.h" #include "system/shmem.h" +#include "system/filesys.h" /************************************************************************* gets a line out of a file. diff --git a/source4/lib/util_sock.c b/source4/lib/util_sock.c index b2f949ebe52..d60fbb34513 100644 --- a/source4/lib/util_sock.c +++ b/source4/lib/util_sock.c @@ -21,6 +21,7 @@ #include "includes.h" #include "system/network.h" +#include "pstring.h" enum SOCK_OPT_TYPES {OPT_BOOL,OPT_INT,OPT_ON}; diff --git a/source4/lib/util_str.c b/source4/lib/util_str.c index d9c4e30d6ae..dc39da50c7c 100644 --- a/source4/lib/util_str.c +++ b/source4/lib/util_str.c @@ -23,6 +23,7 @@ #include "includes.h" #include "system/iconv.h" +#include "pstring.h" /** * @file diff --git a/source4/libcli/auth/gensec_ntlmssp.c b/source4/libcli/auth/gensec_ntlmssp.c index 59bab6ced2e..524815382d6 100644 --- a/source4/libcli/auth/gensec_ntlmssp.c +++ b/source4/libcli/auth/gensec_ntlmssp.c @@ -29,7 +29,7 @@ struct gensec_ntlmssp_state { struct auth_context *auth_context; struct auth_serversupplied_info *server_info; struct ntlmssp_state *ntlmssp_state; - uint32 have_features; + uint32_t have_features; }; @@ -470,7 +470,7 @@ static NTSTATUS gensec_ntlmssp_session_info(struct gensec_security *gensec_secur } static BOOL gensec_ntlmssp_have_feature(struct gensec_security *gensec_security, - uint32 feature) + uint32_t feature) { struct gensec_ntlmssp_state *gensec_ntlmssp_state = gensec_security->private_data; if (gensec_ntlmssp_state->have_features & feature) { diff --git a/source4/libcli/auth/ntlmssp.c b/source4/libcli/auth/ntlmssp.c index d5ddcfbfb62..572ce66bb2e 100644 --- a/source4/libcli/auth/ntlmssp.c +++ b/source4/libcli/auth/ntlmssp.c @@ -24,6 +24,7 @@ #include "includes.h" #include "auth/auth.h" #include "lib/crypto/crypto.h" +#include "pstring.h" static NTSTATUS ntlmssp_client_initial(struct ntlmssp_state *ntlmssp_state, TALLOC_CTX *out_mem_ctx, diff --git a/source4/libcli/auth/ntlmssp_parse.c b/source4/libcli/auth/ntlmssp_parse.c index 543f3d9b61d..42546cb1308 100644 --- a/source4/libcli/auth/ntlmssp_parse.c +++ b/source4/libcli/auth/ntlmssp_parse.c @@ -21,6 +21,7 @@ */ #include "includes.h" +#include "pstring.h" /* this is a tiny msrpc packet generator. I am only using this to diff --git a/source4/libcli/auth/smbencrypt.c b/source4/libcli/auth/smbencrypt.c index 7e2890272cc..00a28a1ad97 100644 --- a/source4/libcli/auth/smbencrypt.c +++ b/source4/libcli/auth/smbencrypt.c @@ -26,6 +26,7 @@ #include "system/time.h" #include "auth/auth.h" #include "lib/crypto/crypto.h" +#include "pstring.h" /* This implements the X/Open SMB password encryption diff --git a/source4/libcli/auth/spnego.c b/source4/libcli/auth/spnego.c index a61680c9d4b..39807671656 100644 --- a/source4/libcli/auth/spnego.c +++ b/source4/libcli/auth/spnego.c @@ -844,7 +844,7 @@ static NTSTATUS gensec_spnego_update(struct gensec_security *gensec_security, TA } static BOOL gensec_spnego_have_feature(struct gensec_security *gensec_security, - uint32 feature) + uint32_t feature) { struct spnego_state *spnego_state = gensec_security->private_data; if (!spnego_state->sub_sec_security) { diff --git a/source4/libcli/ldap/ldap.c b/source4/libcli/ldap/ldap.c index 655838b64f0..545759c494d 100644 --- a/source4/libcli/ldap/ldap.c +++ b/source4/libcli/ldap/ldap.c @@ -25,6 +25,7 @@ #include "includes.h" #include "system/iconv.h" +#include "system/filesys.h" #include "asn_1.h" /**************************************************************************** @@ -697,7 +698,7 @@ static void ldap_decode_response(TALLOC_CTX *mem_ctx, static BOOL ldap_decode_filter(TALLOC_CTX *mem_ctx, struct asn1_data *data, char **filter) { - uint8 filter_tag, tag_desc; + uint8_t filter_tag, tag_desc; if (!asn1_peek_uint8(data, &filter_tag)) return False; @@ -836,7 +837,7 @@ static void ldap_decode_attribs(TALLOC_CTX *mem_ctx, struct asn1_data *data, BOOL ldap_decode(struct asn1_data *data, struct ldap_message *msg) { - uint8 tag; + uint8_t tag; asn1_start_tag(data, ASN1_SEQUENCE(0)); asn1_read_Integer(data, &msg->messageid); diff --git a/source4/libcli/ldap/ldap_client.c b/source4/libcli/ldap/ldap_client.c index 73099ec1be4..ddf0932fa11 100644 --- a/source4/libcli/ldap/ldap_client.c +++ b/source4/libcli/ldap/ldap_client.c @@ -25,6 +25,7 @@ #include "includes.h" #include "system/network.h" +#include "system/filesys.h" #include "auth/auth.h" #include "asn_1.h" #include "dlinklist.h" diff --git a/source4/libcli/raw/clisession.c b/source4/libcli/raw/clisession.c index 30382e08376..4eba4642742 100644 --- a/source4/libcli/raw/clisession.c +++ b/source4/libcli/raw/clisession.c @@ -22,6 +22,7 @@ #include "includes.h" #include "libcli/raw/libcliraw.h" +#include "system/filesys.h" #include "auth/auth.h" #define SETUP_REQUEST_SESSION(cmd, wct, buflen) do { \ diff --git a/source4/libcli/resolve/host.c b/source4/libcli/resolve/host.c index cbf0f4614e5..9f48f83ba42 100644 --- a/source4/libcli/resolve/host.c +++ b/source4/libcli/resolve/host.c @@ -32,6 +32,7 @@ #include "includes.h" #include "lib/events/events.h" #include "system/network.h" +#include "system/filesys.h" #include "libcli/raw/libcliraw.h" #include "libcli/composite/composite.h" diff --git a/source4/libcli/util/doserr.c b/source4/libcli/util/doserr.c index a584def8295..b346fea6445 100644 --- a/source4/libcli/util/doserr.c +++ b/source4/libcli/util/doserr.c @@ -21,6 +21,7 @@ /* DOS error codes. please read doserr.h */ #include "includes.h" +#include "pstring.h" struct werror_code_struct { const char *dos_errstr; diff --git a/source4/libcli/util/nterr.c b/source4/libcli/util/nterr.c index 9317f0e37ae..d727cfe2a9e 100644 --- a/source4/libcli/util/nterr.c +++ b/source4/libcli/util/nterr.c @@ -21,6 +21,7 @@ /* NT error codes. please read nterr.h */ #include "includes.h" +#include "pstring.h" typedef struct { diff --git a/source4/libnet/libnet_join.c b/source4/libnet/libnet_join.c index bf8524c495c..42c041aa83e 100644 --- a/source4/libnet/libnet_join.c +++ b/source4/libnet/libnet_join.c @@ -64,8 +64,8 @@ static NTSTATUS libnet_JoinDomain_samr(struct libnet_context *ctx, struct samr_GetUserPwInfo pwp; struct samr_String samr_account_name; - uint32 acct_flags; - uint32 rid, access_granted; + uint32_t acct_flags; + uint32_t rid, access_granted; int policy_min_pw_len = 0; /* prepare connect to the SAMR pipe of users domain PDC */ diff --git a/source4/libnet/libnet_join.h b/source4/libnet/libnet_join.h index 830599929bc..8614d59a772 100644 --- a/source4/libnet/libnet_join.h +++ b/source4/libnet/libnet_join.h @@ -34,7 +34,7 @@ union libnet_JoinDomain { struct _libnet_JoinDomain_in { const char *domain_name; const char *account_name; - uint32 acct_type; + uint32_t acct_type; } in; struct _libnet_JoinDomain_out { diff --git a/source4/libnet/libnet_rpc.h b/source4/libnet/libnet_rpc.h index 6b1eefd592e..f241aea19ab 100644 --- a/source4/libnet/libnet_rpc.h +++ b/source4/libnet/libnet_rpc.h @@ -53,7 +53,7 @@ union libnet_rpc_connect { const char *server_name; const char *dcerpc_iface_name; const char *dcerpc_iface_uuid; - uint32 dcerpc_iface_version; + uint32_t dcerpc_iface_version; } in; struct _libnet_rpc_connect_out { @@ -70,7 +70,7 @@ union libnet_rpc_connect { const char *domain_name; const char *dcerpc_iface_name; const char *dcerpc_iface_uuid; - uint32 dcerpc_iface_version; + uint32_t dcerpc_iface_version; } in; struct _libnet_rpc_connect_out out; diff --git a/source4/librpc/rpc/dcerpc_util.c b/source4/librpc/rpc/dcerpc_util.c index a78885b3f6f..ac15a62e542 100644 --- a/source4/librpc/rpc/dcerpc_util.c +++ b/source4/librpc/rpc/dcerpc_util.c @@ -465,7 +465,7 @@ NTSTATUS dcerpc_floor_get_lhs_data(struct epm_floor *floor, struct GUID *uuid, u return status; } -DATA_BLOB dcerpc_floor_pack_lhs_data(TALLOC_CTX *mem_ctx, struct GUID *uuid, uint32 if_version) +DATA_BLOB dcerpc_floor_pack_lhs_data(TALLOC_CTX *mem_ctx, struct GUID *uuid, uint32_t if_version) { struct ndr_push *ndr = ndr_push_init_ctx(mem_ctx); diff --git a/source4/nsswitch/wb_common.c b/source4/nsswitch/wb_common.c index a26e430db4f..d7b4614f354 100644 --- a/source4/nsswitch/wb_common.c +++ b/source4/nsswitch/wb_common.c @@ -25,6 +25,7 @@ */ #include "includes.h" +#include "nsswitch/winbind_client.h" /* Global variables. These are effectively the client state information */ diff --git a/source4/ntvfs/common/brlock.c b/source4/ntvfs/common/brlock.c index e88e9638a3f..e693d57ca0c 100644 --- a/source4/ntvfs/common/brlock.c +++ b/source4/ntvfs/common/brlock.c @@ -26,6 +26,7 @@ used. This allows us to provide the same semantics as NT */ #include "includes.h" +#include "system/filesys.h" #include "lib/tdb/include/tdb.h" #include "messages.h" diff --git a/source4/ntvfs/common/opendb.c b/source4/ntvfs/common/opendb.c index be6f3564220..231576b3d5e 100644 --- a/source4/ntvfs/common/opendb.c +++ b/source4/ntvfs/common/opendb.c @@ -39,6 +39,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "lib/tdb/include/tdb.h" #include "messages.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/ntvfs/common/sidmap.c b/source4/ntvfs/common/sidmap.c index 46e02b5da1f..8e040d50818 100644 --- a/source4/ntvfs/common/sidmap.c +++ b/source4/ntvfs/common/sidmap.c @@ -21,6 +21,8 @@ */ #include "includes.h" +#include "system/filesys.h" +#include "system/passwd.h" #include "librpc/gen_ndr/ndr_security.h" /* diff --git a/source4/ntvfs/ipc/ipc_rap.c b/source4/ntvfs/ipc/ipc_rap.c index 7ee7d26e35c..d93b67b7153 100644 --- a/source4/ntvfs/ipc/ipc_rap.c +++ b/source4/ntvfs/ipc/ipc_rap.c @@ -53,14 +53,14 @@ static void rap_heap_restore(struct rap_string_heap *heap, struct rap_call { TALLOC_CTX *mem_ctx; - uint16 callno; + uint16_t callno; const char *paramdesc; const char *datadesc; - uint16 status; - uint16 convert; + uint16_t status; + uint16_t convert; - uint16 rcv_paramlen, rcv_datalen; + uint16_t rcv_paramlen, rcv_datalen; struct ndr_push *ndr_push_param; struct ndr_push *ndr_push_data; @@ -104,7 +104,7 @@ static struct rap_call *new_rap_srv_call(TALLOC_CTX *mem_ctx, return call; } -static NTSTATUS rap_srv_pull_word(struct rap_call *call, uint16 *result) +static NTSTATUS rap_srv_pull_word(struct rap_call *call, uint16_t *result) { if (*call->paramdesc++ != 'W') return NT_STATUS_INVALID_PARAMETER; @@ -112,7 +112,7 @@ static NTSTATUS rap_srv_pull_word(struct rap_call *call, uint16 *result) return ndr_pull_uint16(call->ndr_pull_param, NDR_SCALARS, result); } -static NTSTATUS rap_srv_pull_dword(struct rap_call *call, uint32 *result) +static NTSTATUS rap_srv_pull_dword(struct rap_call *call, uint32_t *result) { if (*call->paramdesc++ != 'D') return NT_STATUS_INVALID_PARAMETER; @@ -135,7 +135,7 @@ static NTSTATUS rap_srv_pull_string(struct rap_call *call, const char **result) return ndr_pull_string(call->ndr_pull_param, NDR_SCALARS, result); } -static NTSTATUS rap_srv_pull_bufsize(struct rap_call *call, uint16 *bufsize) +static NTSTATUS rap_srv_pull_bufsize(struct rap_call *call, uint16_t *bufsize) { NTSTATUS result; diff --git a/source4/ntvfs/nbench/vfs_nbench.c b/source4/ntvfs/nbench/vfs_nbench.c index a1f03da367f..acfa6313d37 100644 --- a/source4/ntvfs/nbench/vfs_nbench.c +++ b/source4/ntvfs/nbench/vfs_nbench.c @@ -25,6 +25,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "smb_server/smb_server.h" /* this is stored in ntvfs_private */ diff --git a/source4/ntvfs/posix/pvfs_acl.c b/source4/ntvfs/posix/pvfs_acl.c index 258d4e5bcb6..7e4b07a9410 100644 --- a/source4/ntvfs/posix/pvfs_acl.c +++ b/source4/ntvfs/posix/pvfs_acl.c @@ -22,7 +22,6 @@ #include "includes.h" #include "auth/auth.h" -#include "system/filesys.h" #include "vfs_posix.h" #include "librpc/gen_ndr/ndr_xattr.h" diff --git a/source4/ntvfs/posix/pvfs_open.c b/source4/ntvfs/posix/pvfs_open.c index ae8841e7b5b..e68670f7cc5 100644 --- a/source4/ntvfs/posix/pvfs_open.c +++ b/source4/ntvfs/posix/pvfs_open.c @@ -23,7 +23,6 @@ #include "includes.h" #include "vfs_posix.h" #include "system/time.h" -#include "system/filesys.h" #include "dlinklist.h" #include "messages.h" #include "librpc/gen_ndr/ndr_xattr.h" diff --git a/source4/ntvfs/posix/pvfs_read.c b/source4/ntvfs/posix/pvfs_read.c index db597d70974..fb656470b88 100644 --- a/source4/ntvfs/posix/pvfs_read.c +++ b/source4/ntvfs/posix/pvfs_read.c @@ -22,7 +22,6 @@ #include "includes.h" #include "vfs_posix.h" -#include "system/filesys.h" #include "librpc/gen_ndr/ndr_security.h" /* diff --git a/source4/ntvfs/posix/pvfs_search.c b/source4/ntvfs/posix/pvfs_search.c index 76c1996ec73..69ca6ef9970 100644 --- a/source4/ntvfs/posix/pvfs_search.c +++ b/source4/ntvfs/posix/pvfs_search.c @@ -23,7 +23,6 @@ #include "includes.h" #include "vfs_posix.h" #include "system/time.h" -#include "system/filesys.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/ntvfs/posix/pvfs_streams.c b/source4/ntvfs/posix/pvfs_streams.c index c9f2fcae290..2ee5034736f 100644 --- a/source4/ntvfs/posix/pvfs_streams.c +++ b/source4/ntvfs/posix/pvfs_streams.c @@ -21,7 +21,6 @@ */ #include "includes.h" -#include "system/filesys.h" #include "vfs_posix.h" #include "librpc/gen_ndr/ndr_xattr.h" diff --git a/source4/ntvfs/posix/vfs_posix.h b/source4/ntvfs/posix/vfs_posix.h index 28f1aab94fa..f779936bf96 100644 --- a/source4/ntvfs/posix/vfs_posix.h +++ b/source4/ntvfs/posix/vfs_posix.h @@ -23,6 +23,7 @@ #ifndef _VFS_POSIX_H_ #define _VFS_POSIX_H_ +#include "system/filesys.h" #include "smb_server/smb_server.h" /* this is the private structure for the posix vfs backend. It is used diff --git a/source4/ntvfs/posix/xattr_system.c b/source4/ntvfs/posix/xattr_system.c index f19177f44c7..3b8becf6fec 100644 --- a/source4/ntvfs/posix/xattr_system.c +++ b/source4/ntvfs/posix/xattr_system.c @@ -21,7 +21,6 @@ */ #include "includes.h" -#include "system/filesys.h" #include "vfs_posix.h" /* diff --git a/source4/ntvfs/simple/svfs_util.c b/source4/ntvfs/simple/svfs_util.c index c44a5274583..3f6e205e71e 100644 --- a/source4/ntvfs/simple/svfs_util.c +++ b/source4/ntvfs/simple/svfs_util.c @@ -24,6 +24,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "svfs.h" #include "system/time.h" #include "system/dir.h" diff --git a/source4/ntvfs/simple/vfs_simple.c b/source4/ntvfs/simple/vfs_simple.c index ace0ad896f9..6f634efd534 100644 --- a/source4/ntvfs/simple/vfs_simple.c +++ b/source4/ntvfs/simple/vfs_simple.c @@ -27,6 +27,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "svfs.h" #include "system/time.h" #include "dlinklist.h" diff --git a/source4/ntvfs/unixuid/vfs_unixuid.c b/source4/ntvfs/unixuid/vfs_unixuid.c index 9915660d9be..d724e7ceb2b 100644 --- a/source4/ntvfs/unixuid/vfs_unixuid.c +++ b/source4/ntvfs/unixuid/vfs_unixuid.c @@ -22,6 +22,8 @@ */ #include "includes.h" +#include "system/filesys.h" +#include "system/passwd.h" #include "auth/auth.h" #include "libcli/security/security.h" #include "smb_server/smb_server.h" diff --git a/source4/passdb/secrets.c b/source4/passdb/secrets.c index 89041fa4ebd..afc26aed46f 100644 --- a/source4/passdb/secrets.c +++ b/source4/passdb/secrets.c @@ -25,6 +25,8 @@ #include "includes.h" #include "lib/tdb/include/tdbutil.h" #include "secrets.h" +#include "system/filesys.h" +#include "pstring.h" #undef DBGC_CLASS #define DBGC_CLASS DBGC_PASSDB diff --git a/source4/rpc_server/dcerpc_server.c b/source4/rpc_server/dcerpc_server.c index 63f8187f24f..c0cd221da6a 100644 --- a/source4/rpc_server/dcerpc_server.c +++ b/source4/rpc_server/dcerpc_server.c @@ -609,7 +609,7 @@ static NTSTATUS dcesrv_auth3(struct dcesrv_call_state *call) /* handle a bind request */ -static NTSTATUS dcesrv_alter_new_context(struct dcesrv_call_state *call, uint32 context_id) +static NTSTATUS dcesrv_alter_new_context(struct dcesrv_call_state *call, uint32_t context_id) { uint32_t if_version, transfer_syntax_version; const char *uuid, *transfer_syntax; diff --git a/source4/rpc_server/dcerpc_sock.c b/source4/rpc_server/dcerpc_sock.c index 3f99b59a4da..fb1ed56f4d8 100644 --- a/source4/rpc_server/dcerpc_sock.c +++ b/source4/rpc_server/dcerpc_sock.c @@ -23,6 +23,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "lib/events/events.h" #include "rpc_server/dcerpc_server.h" #include "smbd/service_stream.h" diff --git a/source4/rpc_server/dcom/rodb.c b/source4/rpc_server/dcom/rodb.c index 56d51c7934a..5008e105bae 100644 --- a/source4/rpc_server/dcom/rodb.c +++ b/source4/rpc_server/dcom/rodb.c @@ -21,6 +21,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "rpc_server/dcerpc_server.h" #include "librpc/gen_ndr/ndr_rot.h" #include "rpc_server/common/common.h" diff --git a/source4/rpc_server/drsuapi/drsuapi_cracknames.c b/source4/rpc_server/drsuapi/drsuapi_cracknames.c index 1e77ae020a2..47a4715cf81 100644 --- a/source4/rpc_server/drsuapi/drsuapi_cracknames.c +++ b/source4/rpc_server/drsuapi/drsuapi_cracknames.c @@ -29,7 +29,7 @@ #include "lib/ldb/include/ldb.h" static WERROR DsCrackNameOneName(struct drsuapi_bind_state *b_state, TALLOC_CTX *mem_ctx, - uint32 format_flags, uint32 format_offered, uint32 format_desired, + uint32_t format_flags, uint32_t format_offered, uint32_t format_desired, const char *name, struct drsuapi_DsNameInfo1 *info1) { int ret; diff --git a/source4/rpc_server/dssetup/dcesrv_dssetup.c b/source4/rpc_server/dssetup/dcesrv_dssetup.c index 2be7c684a4d..5df9c4fc0b5 100644 --- a/source4/rpc_server/dssetup/dcesrv_dssetup.c +++ b/source4/rpc_server/dssetup/dcesrv_dssetup.c @@ -47,7 +47,7 @@ static WERROR dssetup_DsRoleGetPrimaryDomainInformation(struct dcesrv_call_state int ret; struct ldb_message **res; enum dssetup_DsRole role = DS_ROLE_STANDALONE_SERVER; - uint32 flags = 0; + uint32_t flags = 0; const char *domain = NULL; const char *dns_domain = NULL; const char *forest = NULL; diff --git a/source4/rpc_server/echo/rpc_echo.c b/source4/rpc_server/echo/rpc_echo.c index 173e6fbf822..28c9958c924 100644 --- a/source4/rpc_server/echo/rpc_echo.c +++ b/source4/rpc_server/echo/rpc_echo.c @@ -22,6 +22,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "rpc_server/dcerpc_server.h" #include "librpc/gen_ndr/ndr_echo.h" #include "lib/events/events.h" diff --git a/source4/rpc_server/netlogon/dcerpc_netlogon.c b/source4/rpc_server/netlogon/dcerpc_netlogon.c index fac0d75ef1a..67048e4a3de 100644 --- a/source4/rpc_server/netlogon/dcerpc_netlogon.c +++ b/source4/rpc_server/netlogon/dcerpc_netlogon.c @@ -252,7 +252,7 @@ static NTSTATUS netr_ServerAuthenticate(struct dcesrv_call_state *dce_call, TALL * * (I think ... = 0; seems wrong here --metze) */ - uint32 negotiate_flags = 0; + uint32_t negotiate_flags = 0; r3.in.server_name = r->in.server_name; r3.in.account_name = r->in.account_name; @@ -271,7 +271,7 @@ static NTSTATUS netr_ServerAuthenticate2(struct dcesrv_call_state *dce_call, TAL struct netr_ServerAuthenticate2 *r) { struct netr_ServerAuthenticate3 r3; - uint32 rid = 0; + uint32_t rid = 0; r3.in.server_name = r->in.server_name; r3.in.account_name = r->in.account_name; diff --git a/source4/rpc_server/samr/dcesrv_samr.c b/source4/rpc_server/samr/dcesrv_samr.c index 43cad59c7ab..f9752678ad4 100644 --- a/source4/rpc_server/samr/dcesrv_samr.c +++ b/source4/rpc_server/samr/dcesrv_samr.c @@ -35,7 +35,7 @@ This is a bad temporary hack until we have at least some kind of schema support */ -static char *ldb_hexstr(TALLOC_CTX *mem_ctx, uint32 val) +static char *ldb_hexstr(TALLOC_CTX *mem_ctx, uint32_t val) { return talloc_asprintf(mem_ctx, "0x%.8x", val); } @@ -1827,12 +1827,12 @@ static NTSTATUS samr_QueryGroupMember(struct dcesrv_call_state *dce_call, TALLOC array->count = el->num_values; - array->rids = talloc_array(mem_ctx, uint32, + array->rids = talloc_array(mem_ctx, uint32_t, el->num_values); if (array->rids == NULL) return NT_STATUS_NO_MEMORY; - array->unknown = talloc_array(mem_ctx, uint32, + array->unknown = talloc_array(mem_ctx, uint32_t, el->num_values); if (array->unknown == NULL) return NT_STATUS_NO_MEMORY; diff --git a/source4/rpc_server/winreg/rpc_winreg.c b/source4/rpc_server/winreg/rpc_winreg.c index c0da3cbb113..050df297271 100644 --- a/source4/rpc_server/winreg/rpc_winreg.c +++ b/source4/rpc_server/winreg/rpc_winreg.c @@ -353,7 +353,7 @@ static WERROR winreg_QueryValue(struct dcesrv_call_state *dce_call, TALLOC_CTX * r->out.type = &val->data_type; r->out.length = &val->data_len; if (!r->in.data) { - r->out.size = talloc(mem_ctx, uint32); + r->out.size = talloc(mem_ctx, uint32_t); *r->out.size = val->data_len; } else { r->out.size = r->in.size; diff --git a/source4/smbd/process_standard.c b/source4/smbd/process_standard.c index 5439e5235a5..014bd34afd6 100644 --- a/source4/smbd/process_standard.c +++ b/source4/smbd/process_standard.c @@ -27,6 +27,7 @@ #include "lib/tdb/include/tdb.h" #include "dlinklist.h" #include "smb_server/smb_server.h" +#include "system/filesys.h" /* called when the process model is selected diff --git a/source4/smbd/server.c b/source4/smbd/server.c index 43d9364c9e3..9bf71702f23 100644 --- a/source4/smbd/server.c +++ b/source4/smbd/server.c @@ -29,6 +29,7 @@ #include "dynconfig.h" #include "lib/cmdline/popt_common.h" #include "system/dir.h" +#include "system/filesys.h" /* diff --git a/source4/torture/basic/delaywrite.c b/source4/torture/basic/delaywrite.c index 27a7c92eed1..b0d92d005dc 100644 --- a/source4/torture/basic/delaywrite.c +++ b/source4/torture/basic/delaywrite.c @@ -25,6 +25,7 @@ #include "includes.h" #include "libcli/raw/libcliraw.h" #include "system/time.h" +#include "system/filesys.h" #define BASEDIR "\\delaywrite" diff --git a/source4/torture/basic/delete.c b/source4/torture/basic/delete.c index 3247a7cd287..f3aef08ce1d 100644 --- a/source4/torture/basic/delete.c +++ b/source4/torture/basic/delete.c @@ -21,6 +21,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/torture/basic/denytest.c b/source4/torture/basic/denytest.c index 7308805da7d..35c22ff19f1 100644 --- a/source4/torture/basic/denytest.c +++ b/source4/torture/basic/denytest.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "libcli/raw/libcliraw.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/torture/basic/dir.c b/source4/torture/basic/dir.c index d7721ce5ae5..59cd21f06d1 100644 --- a/source4/torture/basic/dir.c +++ b/source4/torture/basic/dir.c @@ -21,6 +21,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "librpc/gen_ndr/ndr_security.h" static void list_fn(struct clilist_file_info *finfo, const char *name, void *state) diff --git a/source4/torture/basic/disconnect.c b/source4/torture/basic/disconnect.c index 2a302ae3f6d..fab9733eb00 100644 --- a/source4/torture/basic/disconnect.c +++ b/source4/torture/basic/disconnect.c @@ -21,6 +21,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "libcli/raw/libcliraw.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/torture/basic/locking.c b/source4/torture/basic/locking.c index 00310e54055..c3feaae2eb2 100644 --- a/source4/torture/basic/locking.c +++ b/source4/torture/basic/locking.c @@ -24,6 +24,7 @@ #include "includes.h" #include "libcli/raw/libcliraw.h" #include "system/time.h" +#include "system/filesys.h" #define BASEDIR "\\locktest" diff --git a/source4/torture/basic/mangle_test.c b/source4/torture/basic/mangle_test.c index a0333b1c53b..3ea2644d1a2 100644 --- a/source4/torture/basic/mangle_test.c +++ b/source4/torture/basic/mangle_test.c @@ -19,7 +19,9 @@ */ #include "includes.h" +#include "system/filesys.h" #include "lib/tdb/include/tdbutil.h" +#include "pstring.h" static TDB_CONTEXT *tdb; diff --git a/source4/torture/basic/scanner.c b/source4/torture/basic/scanner.c index b1bbdf1cd17..df9234feca5 100644 --- a/source4/torture/basic/scanner.c +++ b/source4/torture/basic/scanner.c @@ -20,7 +20,9 @@ #include "includes.h" #include "libcli/raw/libcliraw.h" +#include "system/filesys.h" #include "librpc/gen_ndr/ndr_security.h" +#include "pstring.h" #define VERBOSE 0 #define OP_MIN 0 diff --git a/source4/torture/basic/unlink.c b/source4/torture/basic/unlink.c index 30d862e3453..40a486f93f9 100644 --- a/source4/torture/basic/unlink.c +++ b/source4/torture/basic/unlink.c @@ -21,6 +21,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "libcli/raw/libcliraw.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/torture/basic/utable.c b/source4/torture/basic/utable.c index 01984077a35..ea1bb76b8c5 100644 --- a/source4/torture/basic/utable.c +++ b/source4/torture/basic/utable.c @@ -20,7 +20,9 @@ #include "includes.h" #include "system/iconv.h" +#include "system/filesys.h" #include "librpc/gen_ndr/ndr_security.h" +#include "pstring.h" BOOL torture_utable(void) { diff --git a/source4/torture/gentest.c b/source4/torture/gentest.c index 87d49c6ce5f..19fa03df8c8 100644 --- a/source4/torture/gentest.c +++ b/source4/torture/gentest.c @@ -21,6 +21,7 @@ #include "includes.h" #include "dynconfig.h" #include "system/time.h" +#include "system/filesys.h" #include "request.h" #include "libcli/raw/libcliraw.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/torture/local/messaging.c b/source4/torture/local/messaging.c index 958fcaa8f08..f12f3f6bdf8 100644 --- a/source4/torture/local/messaging.c +++ b/source4/torture/local/messaging.c @@ -21,6 +21,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "lib/events/events.h" enum {MY_PING=1000, MY_PONG, MY_EXIT}; diff --git a/source4/torture/locktest.c b/source4/torture/locktest.c index 161f51e1da6..74f348638ca 100644 --- a/source4/torture/locktest.c +++ b/source4/torture/locktest.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "dynconfig.h" #include "system/time.h" diff --git a/source4/torture/masktest.c b/source4/torture/masktest.c index a560c19f44b..4c71385ad09 100644 --- a/source4/torture/masktest.c +++ b/source4/torture/masktest.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "dynconfig.h" #include "clilist.h" #include "libcli/raw/libcliraw.h" diff --git a/source4/torture/nbench/nbench.c b/source4/torture/nbench/nbench.c index afd71537a91..748ff904674 100644 --- a/source4/torture/nbench/nbench.c +++ b/source4/torture/nbench/nbench.c @@ -19,6 +19,8 @@ */ #include "includes.h" +#include "system/filesys.h" +#include "pstring.h" int nbench_line_count = 0; static int timelimit = 600; diff --git a/source4/torture/nbench/nbio.c b/source4/torture/nbench/nbio.c index 1864c82fdcb..1cb00b67331 100644 --- a/source4/torture/nbench/nbio.c +++ b/source4/torture/nbench/nbio.c @@ -22,6 +22,7 @@ #include "includes.h" #include "system/time.h" +#include "system/filesys.h" #include "dlinklist.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/torture/rap/rap.c b/source4/torture/rap/rap.c index f46c00eaead..f245bc679e0 100644 --- a/source4/torture/rap/rap.c +++ b/source4/torture/rap/rap.c @@ -23,14 +23,14 @@ #include "rap.h" struct rap_call { - uint16 callno; + uint16_t callno; char *paramdesc; const char *datadesc; - uint16 status; - uint16 convert; + uint16_t status; + uint16_t convert; - uint16 rcv_paramlen, rcv_datalen; + uint16_t rcv_paramlen, rcv_datalen; struct ndr_push *ndr_push_param; struct ndr_push *ndr_push_data; @@ -40,7 +40,7 @@ struct rap_call { #define RAPNDR_FLAGS (LIBNDR_FLAG_NOALIGN|LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_NULLTERM); -static struct rap_call *new_rap_cli_call(TALLOC_CTX *mem_ctx, uint16 callno) +static struct rap_call *new_rap_cli_call(TALLOC_CTX *mem_ctx, uint16_t callno) { struct rap_call *call; @@ -80,13 +80,13 @@ static void rap_cli_push_paramdesc(struct rap_call *call, char desc) call->paramdesc[len+1] = '\0'; } -static void rap_cli_push_word(struct rap_call *call, uint16 val) +static void rap_cli_push_word(struct rap_call *call, uint16_t val) { rap_cli_push_paramdesc(call, 'W'); ndr_push_uint16(call->ndr_push_param, NDR_SCALARS, val); } -static void rap_cli_push_dword(struct rap_call *call, uint32 val) +static void rap_cli_push_dword(struct rap_call *call, uint32_t val) { rap_cli_push_paramdesc(call, 'D'); ndr_push_uint32(call->ndr_push_param, NDR_SCALARS, val); @@ -104,7 +104,7 @@ static void rap_cli_expect_multiple_entries(struct rap_call *call) { rap_cli_push_paramdesc(call, 'e'); rap_cli_push_paramdesc(call, 'h'); - call->rcv_paramlen += 4; /* uint16 entry count, uint16 total */ + call->rcv_paramlen += 4; /* uint16_t entry count, uint16_t total */ } static void rap_cli_push_string(struct rap_call *call, const char *str) @@ -123,10 +123,10 @@ static void rap_cli_expect_format(struct rap_call *call, const char *format) } static NTSTATUS rap_pull_string(TALLOC_CTX *mem_ctx, struct ndr_pull *ndr, - uint16 convert, char **dest) + uint16_t convert, char **dest) { - uint16 string_offset; - uint16 ignore; + uint16_t string_offset; + uint16_t ignore; const char *p; size_t len; diff --git a/source4/torture/raw/acls.c b/source4/torture/raw/acls.c index fd1ea0f3409..f6a51a8d91e 100644 --- a/source4/torture/raw/acls.c +++ b/source4/torture/raw/acls.c @@ -21,6 +21,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "libcli/raw/libcliraw.h" #include "librpc/gen_ndr/ndr_security.h" @@ -843,7 +844,7 @@ static BOOL test_owner_bits(struct smbcli_state *cli, TALLOC_CTX *mem_ctx) expected_bits = SEC_FILE_WRITE_DATA | SEC_FILE_READ_ATTRIBUTE; for (i=0;i<16;i++) { - uint32 bit = (1<<i); + uint32_t bit = (1<<i); io.ntcreatex.in.access_mask = bit; status = smb_raw_open(cli->tree, mem_ctx, &io); if (expected_bits & bit) { diff --git a/source4/torture/raw/lock.c b/source4/torture/raw/lock.c index f2cd5b7cf71..97242e8f176 100644 --- a/source4/torture/raw/lock.c +++ b/source4/torture/raw/lock.c @@ -21,6 +21,7 @@ #include "includes.h" #include "libcli/raw/libcliraw.h" #include "system/time.h" +#include "system/filesys.h" #define CHECK_STATUS(status, correct) do { \ if (!NT_STATUS_EQUAL(status, correct)) { \ diff --git a/source4/torture/raw/mux.c b/source4/torture/raw/mux.c index e8f7e4a7121..379e455b2b5 100644 --- a/source4/torture/raw/mux.c +++ b/source4/torture/raw/mux.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "libcli/raw/libcliraw.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/torture/raw/open.c b/source4/torture/raw/open.c index 17a7f18505a..8792ab7caba 100644 --- a/source4/torture/raw/open.c +++ b/source4/torture/raw/open.c @@ -21,6 +21,7 @@ #include "includes.h" #include "libcli/raw/libcliraw.h" #include "system/time.h" +#include "system/filesys.h" #include "librpc/gen_ndr/ndr_security.h" /* enum for whether reads/writes are possible on a file */ diff --git a/source4/torture/raw/read.c b/source4/torture/raw/read.c index e8e305d01c1..3e27f4b0bb6 100644 --- a/source4/torture/raw/read.c +++ b/source4/torture/raw/read.c @@ -21,6 +21,7 @@ #include "includes.h" #include "libcli/raw/libcliraw.h" #include "system/time.h" +#include "system/filesys.h" #define CHECK_STATUS(status, correct) do { \ if (!NT_STATUS_EQUAL(status, correct)) { \ diff --git a/source4/torture/raw/search.c b/source4/torture/raw/search.c index be54aecb3dd..0f04648672a 100644 --- a/source4/torture/raw/search.c +++ b/source4/torture/raw/search.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "libcli/raw/libcliraw.h" diff --git a/source4/torture/raw/seek.c b/source4/torture/raw/seek.c index 0d34c831a52..9652b7597f8 100644 --- a/source4/torture/raw/seek.c +++ b/source4/torture/raw/seek.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "system/filesys.h" #define CHECK_STATUS(status, correct) do { \ if (!NT_STATUS_EQUAL(status, correct)) { \ diff --git a/source4/torture/raw/streams.c b/source4/torture/raw/streams.c index 54c83de8963..6753234af45 100644 --- a/source4/torture/raw/streams.c +++ b/source4/torture/raw/streams.c @@ -23,6 +23,7 @@ #include "includes.h" #include "libcli/raw/libcliraw.h" #include "librpc/gen_ndr/ndr_security.h" +#include "system/filesys.h" #define BASEDIR "\\teststreams" diff --git a/source4/torture/raw/unlink.c b/source4/torture/raw/unlink.c index 1c8c35d72fd..5874da6ef7b 100644 --- a/source4/torture/raw/unlink.c +++ b/source4/torture/raw/unlink.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "system/filesys.h" #define CHECK_STATUS(status, correct) do { \ if (!NT_STATUS_EQUAL(status, correct)) { \ diff --git a/source4/torture/raw/write.c b/source4/torture/raw/write.c index 7241f8c91a5..dead0e49717 100644 --- a/source4/torture/raw/write.c +++ b/source4/torture/raw/write.c @@ -22,6 +22,7 @@ #include "includes.h" #include "libcli/raw/libcliraw.h" #include "system/time.h" +#include "system/filesys.h" #define CHECK_STATUS(status, correct) do { \ if (!NT_STATUS_EQUAL(status, correct)) { \ diff --git a/source4/torture/rpc/lsa.c b/source4/torture/rpc/lsa.c index 089f58dc991..277a5fc793b 100644 --- a/source4/torture/rpc/lsa.c +++ b/source4/torture/rpc/lsa.c @@ -1141,7 +1141,7 @@ static BOOL test_LookupPrivDisplayName(struct dcerpc_pipe *p, NTSTATUS status; /* produce a reasonable range of language output without screwing up terminals */ - uint16 language_id = (random() % 4) + 0x409; + uint16_t language_id = (random() % 4) + 0x409; printf("testing LookupPrivDisplayName(%s)\n", priv_name->string); diff --git a/source4/torture/rpc/netlogon.c b/source4/torture/rpc/netlogon.c index e3c2be038a8..7c516da1180 100644 --- a/source4/torture/rpc/netlogon.c +++ b/source4/torture/rpc/netlogon.c @@ -199,7 +199,7 @@ BOOL test_SetupCredentials3(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, struct netr_ServerAuthenticate3 a; struct netr_Credential credentials1, credentials2, credentials3; struct samr_Password mach_password; - uint32 rid; + uint32_t rid; printf("Testing ServerReqChallenge\n"); diff --git a/source4/torture/rpc/oxidresolve.c b/source4/torture/rpc/oxidresolve.c index b565d5de761..6164825af73 100644 --- a/source4/torture/rpc/oxidresolve.c +++ b/source4/torture/rpc/oxidresolve.c @@ -33,7 +33,7 @@ static int test_RemoteActivation(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, uin struct RemoteActivation r; NTSTATUS status; struct GUID iids[2]; - uint16 protseq[3] = { EPM_PROTOCOL_TCP, EPM_PROTOCOL_NCALRPC, EPM_PROTOCOL_UUID }; + uint16_t protseq[3] = { EPM_PROTOCOL_TCP, EPM_PROTOCOL_NCALRPC, EPM_PROTOCOL_UUID }; ZERO_STRUCT(r.in); r.in.this.version.MajorVersion = 5; @@ -147,7 +147,7 @@ static int test_ResolveOxid(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, uint64_t { struct ResolveOxid r; NTSTATUS status; - uint16 protseq[2] = { EPM_PROTOCOL_TCP, EPM_PROTOCOL_SMB }; + uint16_t protseq[2] = { EPM_PROTOCOL_TCP, EPM_PROTOCOL_SMB }; r.in.pOxid = oxid; r.in.cRequestedProtseqs = 2; @@ -171,7 +171,7 @@ static int test_ResolveOxid2(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, uint64_ { struct ResolveOxid2 r; NTSTATUS status; - uint16 protseq[2] = { EPM_PROTOCOL_TCP, EPM_PROTOCOL_SMB }; + uint16_t protseq[2] = { EPM_PROTOCOL_TCP, EPM_PROTOCOL_SMB }; r.in.pOxid = oxid; r.in.cRequestedProtseqs = 2; diff --git a/source4/torture/rpc/remact.c b/source4/torture/rpc/remact.c index aaef981fdbb..269c92a5b44 100644 --- a/source4/torture/rpc/remact.c +++ b/source4/torture/rpc/remact.c @@ -32,7 +32,7 @@ static int test_RemoteActivation(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx) struct RemoteActivation r; NTSTATUS status; struct GUID iids[2]; - uint16 protseq[3] = { EPM_PROTOCOL_TCP, EPM_PROTOCOL_NCALRPC, EPM_PROTOCOL_UUID }; + uint16_t protseq[3] = { EPM_PROTOCOL_TCP, EPM_PROTOCOL_NCALRPC, EPM_PROTOCOL_UUID }; ZERO_STRUCT(r.in); r.in.this.version.MajorVersion = 5; diff --git a/source4/torture/rpc/samlogon.c b/source4/torture/rpc/samlogon.c index 1c7e3e03501..06988459fd2 100644 --- a/source4/torture/rpc/samlogon.c +++ b/source4/torture/rpc/samlogon.c @@ -73,7 +73,7 @@ static NTSTATUS check_samlogon(struct samlogon_state *samlogon_state, struct netr_LogonSamLogonWithFlags *r_flags = &samlogon_state->r_flags; struct netr_NetworkInfo ninfo; struct netr_SamBaseInfo *base = NULL; - uint16 validation_level = 0; + uint16_t validation_level = 0; samlogon_state->r.in.logon.network = &ninfo; samlogon_state->r_ex.in.logon.network = &ninfo; diff --git a/source4/torture/rpc/samr.c b/source4/torture/rpc/samr.c index fa64b556ef8..31380c109a6 100644 --- a/source4/torture/rpc/samr.c +++ b/source4/torture/rpc/samr.c @@ -433,7 +433,7 @@ static BOOL test_SetUserPass(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, static BOOL test_SetUserPass_23(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, - struct policy_handle *handle, uint32 fields_present, + struct policy_handle *handle, uint32_t fields_present, char **password) { NTSTATUS status; @@ -547,7 +547,7 @@ static BOOL test_SetUserPassEx(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, } static BOOL test_SetUserPass_25(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, - struct policy_handle *handle, uint32 fields_present, + struct policy_handle *handle, uint32_t fields_present, char **password) { NTSTATUS status; @@ -1546,7 +1546,7 @@ static BOOL test_CreateUser(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, char *password = NULL; int i; - const uint32 password_fields[] = { + const uint32_t password_fields[] = { SAMR_FIELD_PASSWORD, SAMR_FIELD_PASSWORD2, SAMR_FIELD_PASSWORD | SAMR_FIELD_PASSWORD2, diff --git a/source4/torture/rpc/samsync.c b/source4/torture/rpc/samsync.c index f7800e28ccb..3fc916450f7 100644 --- a/source4/torture/rpc/samsync.c +++ b/source4/torture/rpc/samsync.c @@ -389,7 +389,7 @@ static BOOL samsync_handle_policy(TALLOC_CTX *mem_ctx, struct samsync_state *sam static BOOL samsync_handle_user(TALLOC_CTX *mem_ctx, struct samsync_state *samsync_state, int database_id, struct netr_DELTA_ENUM *delta) { - uint32 rid = delta->delta_id_union.rid; + uint32_t rid = delta->delta_id_union.rid; struct netr_DELTA_USER *user = delta->delta_union.user; struct netr_SamInfo3 *info3; struct samr_Password lm_hash; @@ -604,7 +604,7 @@ static BOOL samsync_handle_user(TALLOC_CTX *mem_ctx, struct samsync_state *samsy static BOOL samsync_handle_alias(TALLOC_CTX *mem_ctx, struct samsync_state *samsync_state, int database_id, struct netr_DELTA_ENUM *delta) { - uint32 rid = delta->delta_id_union.rid; + uint32_t rid = delta->delta_id_union.rid; struct netr_DELTA_ALIAS *alias = delta->delta_union.alias; NTSTATUS nt_status; BOOL ret = True; @@ -653,7 +653,7 @@ static BOOL samsync_handle_alias(TALLOC_CTX *mem_ctx, struct samsync_state *sams static BOOL samsync_handle_group(TALLOC_CTX *mem_ctx, struct samsync_state *samsync_state, int database_id, struct netr_DELTA_ENUM *delta) { - uint32 rid = delta->delta_id_union.rid; + uint32_t rid = delta->delta_id_union.rid; struct netr_DELTA_GROUP *group = delta->delta_union.group; NTSTATUS nt_status; BOOL ret = True; diff --git a/source4/torture/rpc/schannel.c b/source4/torture/rpc/schannel.c index bf225a16021..26f186e912a 100644 --- a/source4/torture/rpc/schannel.c +++ b/source4/torture/rpc/schannel.c @@ -114,8 +114,8 @@ static BOOL test_netlogon_ops(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, test a schannel connection with the given flags */ static BOOL test_schannel(TALLOC_CTX *mem_ctx, - uint16 acct_flags, uint32 dcerpc_flags, - uint32 schannel_type) + uint16_t acct_flags, uint32_t dcerpc_flags, + uint32_t schannel_type) { void *join_ctx; const char *machine_password; @@ -215,9 +215,9 @@ BOOL torture_rpc_schannel(void) TALLOC_CTX *mem_ctx; BOOL ret = True; struct { - uint16 acct_flags; - uint32 dcerpc_flags; - uint32 schannel_type; + uint16_t acct_flags; + uint32_t dcerpc_flags; + uint32_t schannel_type; } tests[] = { { ACB_WSTRUST, DCERPC_SCHANNEL_WORKSTATION | DCERPC_SIGN, 3 }, { ACB_WSTRUST, DCERPC_SCHANNEL_WORKSTATION | DCERPC_SEAL, 3 }, diff --git a/source4/torture/rpc/srvsvc.c b/source4/torture/rpc/srvsvc.c index 4b1305b7b6b..697ae4afe78 100644 --- a/source4/torture/rpc/srvsvc.c +++ b/source4/torture/rpc/srvsvc.c @@ -105,7 +105,7 @@ static BOOL test_NetCharDevEnum(struct dcerpc_pipe *p, r.in.ctr.ctr0 = &c0; r.in.ctr.ctr0->count = 0; r.in.ctr.ctr0->array = NULL; - r.in.max_buffer = (uint32)-1; + r.in.max_buffer = (uint32_t)-1; r.in.resume_handle = NULL; for (i=0;i<ARRAY_SIZE(levels);i++) { @@ -252,7 +252,7 @@ static BOOL test_NetCharDevQEnum(struct dcerpc_pipe *p, r.in.ctr.ctr0 = &c0; r.in.ctr.ctr0->count = 0; r.in.ctr.ctr0->array = NULL; - r.in.max_buffer = (uint32)-1; + r.in.max_buffer = (uint32_t)-1; r.in.resume_handle = NULL; for (i=0;i<ARRAY_SIZE(levels);i++) { diff --git a/source4/torture/rpc/svcctl.c b/source4/torture/rpc/svcctl.c index cadc80a4175..092329ab68f 100644 --- a/source4/torture/rpc/svcctl.c +++ b/source4/torture/rpc/svcctl.c @@ -28,7 +28,7 @@ static BOOL test_EnumServicesStatus(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, struct svcctl_EnumServicesStatusW r; int i; NTSTATUS status; - uint32 resume_handle = 0; + uint32_t resume_handle = 0; struct ENUM_SERVICE_STATUS *service = NULL; r.in.handle = h; diff --git a/source4/torture/rpc/winreg.c b/source4/torture/rpc/winreg.c index f2d79fffa0e..9d259ae47a9 100644 --- a/source4/torture/rpc/winreg.c +++ b/source4/torture/rpc/winreg.c @@ -365,9 +365,9 @@ static BOOL test_QueryMultipleValues(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, r.in.values[0].type = 0; r.in.num_values = 1; - r.in.buffer_size = r.out.buffer_size = talloc(mem_ctx, uint32); + r.in.buffer_size = r.out.buffer_size = talloc(mem_ctx, uint32_t); *r.in.buffer_size = 0x20; - r.in.buffer = r.out.buffer = talloc_zero_array(mem_ctx, uint8, *r.in.buffer_size); + r.in.buffer = r.out.buffer = talloc_zero_array(mem_ctx, uint8_t, *r.in.buffer_size); status = dcerpc_winreg_QueryMultipleValues(p, mem_ctx, &r); if(NT_STATUS_IS_ERR(status)) { @@ -387,8 +387,8 @@ static BOOL test_QueryValue(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, struct p { struct winreg_QueryValue r; NTSTATUS status; - uint32 zero = 0; - uint32 offered = 0xfff; + uint32_t zero = 0; + uint32_t offered = 0xfff; printf("Testing QueryValue\n"); @@ -417,8 +417,8 @@ static BOOL test_EnumValue(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, struct policy_handle *handle, int max_valnamelen, int max_valbufsize) { struct winreg_EnumValue r; - uint32 type = 0; - uint32 size = max_valbufsize, zero = 0; + uint32_t type = 0; + uint32_t size = max_valbufsize, zero = 0; BOOL ret = True; uint8_t buf8; uint16_t buf16; diff --git a/source4/torture/torture.c b/source4/torture/torture.c index 12b12147234..b7ca730d1f3 100644 --- a/source4/torture/torture.c +++ b/source4/torture/torture.c @@ -25,6 +25,7 @@ #include "libcli/raw/libcliraw.h" #include "system/time.h" #include "system/wait.h" +#include "system/filesys.h" #include "ioctl.h" #include "librpc/gen_ndr/ndr_security.h" diff --git a/source4/utils/net/net_password.c b/source4/utils/net/net_password.c index 8828b960ee3..773e18d6610 100644 --- a/source4/utils/net/net_password.c +++ b/source4/utils/net/net_password.c @@ -22,6 +22,7 @@ #include "includes.h" #include "utils/net/net.h" #include "libnet/libnet.h" +#include "system/filesys.h" #include "system/passwd.h" /* diff --git a/source4/utils/ntlm_auth.c b/source4/utils/ntlm_auth.c index b5e3f3b3ea3..3c46b0ca702 100644 --- a/source4/utils/ntlm_auth.c +++ b/source4/utils/ntlm_auth.c @@ -25,6 +25,7 @@ #include "includes.h" #include "dynconfig.h" #include "system/passwd.h" +#include "system/filesys.h" #include "lib/cmdline/popt_common.h" #include "auth/auth.h" #include "libcli/security/security.h" @@ -145,7 +146,7 @@ static NTSTATUS local_pw_check_specified(const char *username, const DATA_BLOB *challenge, const DATA_BLOB *lm_response, const DATA_BLOB *nt_response, - uint32 flags, + uint32_t flags, DATA_BLOB *lm_session_key, DATA_BLOB *user_session_key, char **error_string, @@ -564,7 +565,7 @@ static void manage_ntlm_server_1_request(enum stdio_helper_mode stdio_helper_mod char *error_string = NULL; DATA_BLOB lm_key; DATA_BLOB user_session_key; - uint32 flags = 0; + uint32_t flags = 0; if (full_username && !username) { fstring fstr_user; diff --git a/source4/winbind/wb_server.c b/source4/winbind/wb_server.c index e39aed91d72..c277772e1e5 100644 --- a/source4/winbind/wb_server.c +++ b/source4/winbind/wb_server.c @@ -21,6 +21,7 @@ */ #include "includes.h" +#include "system/filesys.h" #include "dlinklist.h" #include "lib/events/events.h" #include "smbd/service_task.h" |