diff options
-rw-r--r-- | source3/libsmb/cliconnect.c | 8 | ||||
-rw-r--r-- | source3/libsmb/clidgram.c | 2 | ||||
-rw-r--r-- | source3/libsmb/clientgen.c | 2 | ||||
-rw-r--r-- | source3/libsmb/clierror.c | 6 | ||||
-rw-r--r-- | source3/libsmb/clifsinfo.c | 22 | ||||
-rw-r--r-- | source3/libsmb/clilist.c | 6 | ||||
-rw-r--r-- | source3/libsmb/clirap.c | 26 | ||||
-rw-r--r-- | source3/libsmb/clirap.h | 48 | ||||
-rw-r--r-- | source3/libsmb/clirap2.c | 30 | ||||
-rw-r--r-- | source3/libsmb/clisecdesc.c | 4 | ||||
-rw-r--r-- | source3/libsmb/libsmb_dir.c | 18 | ||||
-rw-r--r-- | source3/libsmb/libsmb_file.c | 6 | ||||
-rw-r--r-- | source3/libsmb/libsmb_misc.c | 4 | ||||
-rw-r--r-- | source3/libsmb/libsmb_server.c | 2 | ||||
-rw-r--r-- | source3/libsmb/libsmb_stat.c | 10 | ||||
-rw-r--r-- | source3/libsmb/libsmb_xattr.c | 14 | ||||
-rw-r--r-- | source3/libsmb/namequery.c | 4 | ||||
-rw-r--r-- | source3/libsmb/nmblib.c | 2 | ||||
-rw-r--r-- | source3/libsmb/proto.h | 26 | ||||
-rw-r--r-- | source3/libsmb/samlogon_cache.c | 2 | ||||
-rw-r--r-- | source3/libsmb/smb_share_modes.c | 18 | ||||
-rw-r--r-- | source3/libsmb/smbsock_connect.c | 2 |
22 files changed, 131 insertions, 131 deletions
diff --git a/source3/libsmb/cliconnect.c b/source3/libsmb/cliconnect.c index 4cb4ed4d927..530f5c36b1b 100644 --- a/source3/libsmb/cliconnect.c +++ b/source3/libsmb/cliconnect.c @@ -2401,7 +2401,7 @@ struct tevent_req *cli_tcon_andx_create(TALLOC_CTX *mem_ctx, * Non-encrypted passwords - convert to DOS codepage * before using. */ - tmp_pass = talloc_array(talloc_tos(), uint8, 0); + tmp_pass = talloc_array(talloc_tos(), uint8_t, 0); if (tevent_req_nomem(tmp_pass, req)) { return tevent_req_post(req, ev); } @@ -2628,7 +2628,7 @@ static struct tevent_req *cli_raw_tcon_send( TALLOC_CTX *mem_ctx, struct tevent_context *ev, struct cli_state *cli, const char *service, const char *pass, const char *dev); static NTSTATUS cli_raw_tcon_recv(struct tevent_req *req, - uint16 *max_xmit, uint16 *tid); + uint16_t *max_xmit, uint16_t *tid); static void cli_tree_connect_smb2_done(struct tevent_req *subreq); static void cli_tree_connect_andx_done(struct tevent_req *subreq); @@ -3523,7 +3523,7 @@ static void cli_raw_tcon_done(struct tevent_req *subreq) } static NTSTATUS cli_raw_tcon_recv(struct tevent_req *req, - uint16 *max_xmit, uint16 *tid) + uint16_t *max_xmit, uint16_t *tid) { struct cli_raw_tcon_state *state = tevent_req_data( req, struct cli_raw_tcon_state); @@ -3539,7 +3539,7 @@ static NTSTATUS cli_raw_tcon_recv(struct tevent_req *req, NTSTATUS cli_raw_tcon(struct cli_state *cli, const char *service, const char *pass, const char *dev, - uint16 *max_xmit, uint16 *tid) + uint16_t *max_xmit, uint16_t *tid) { struct tevent_context *ev; struct tevent_req *req; diff --git a/source3/libsmb/clidgram.c b/source3/libsmb/clidgram.c index be237540316..d8fa1c6b935 100644 --- a/source3/libsmb/clidgram.c +++ b/source3/libsmb/clidgram.c @@ -33,7 +33,7 @@ */ static bool cli_prep_mailslot(bool unique, const char *mailslot, - uint16 priority, + uint16_t priority, char *buf, int len, const char *srcname, int src_type, const char *dstname, int dest_type, diff --git a/source3/libsmb/clientgen.c b/source3/libsmb/clientgen.c index 3b737d44cab..166918efc43 100644 --- a/source3/libsmb/clientgen.c +++ b/source3/libsmb/clientgen.c @@ -318,7 +318,7 @@ uint16_t cli_state_get_vc_num(struct cli_state *cli) Set the PID to use for smb messages. Return the old pid. ****************************************************************************/ -uint16 cli_setpid(struct cli_state *cli, uint16 pid) +uint16_t cli_setpid(struct cli_state *cli, uint16 pid) { uint16_t ret = cli->smb1.pid; cli->smb1.pid = pid; diff --git a/source3/libsmb/clierror.c b/source3/libsmb/clierror.c index a53c9c4e1e8..f20980251f4 100644 --- a/source3/libsmb/clierror.c +++ b/source3/libsmb/clierror.c @@ -84,7 +84,7 @@ NTSTATUS cli_nt_error(struct cli_state *cli) code. ****************************************************************************/ -void cli_dos_error(struct cli_state *cli, uint8 *eclass, uint32 *ecode) +void cli_dos_error(struct cli_state *cli, uint8_t *eclass, uint32_t *ecode) { if (!cli_state_is_connected(cli)) { *eclass = ERRDOS; @@ -115,8 +115,8 @@ int cli_errno(struct cli_state *cli) } if (cli_is_dos_error(cli)) { - uint8 eclass; - uint32 ecode; + uint8_t eclass; + uint32_t ecode; cli_dos_error(cli, &eclass, &ecode); status = dos_to_ntstatus(eclass, ecode); diff --git a/source3/libsmb/clifsinfo.c b/source3/libsmb/clifsinfo.c index 376c4f5d5b1..3fbfbbe67a6 100644 --- a/source3/libsmb/clifsinfo.c +++ b/source3/libsmb/clifsinfo.c @@ -120,9 +120,9 @@ NTSTATUS cli_unix_extensions_version_recv(struct tevent_req *req, return NT_STATUS_OK; } -NTSTATUS cli_unix_extensions_version(struct cli_state *cli, uint16 *pmajor, - uint16 *pminor, uint32 *pcaplow, - uint32 *pcaphigh) +NTSTATUS cli_unix_extensions_version(struct cli_state *cli, uint16_t *pmajor, + uint16_t *pminor, uint32_t *pcaplow, + uint32_t *pcaphigh) { TALLOC_CTX *frame = talloc_stackframe(); struct tevent_context *ev; @@ -235,8 +235,8 @@ NTSTATUS cli_set_unix_extensions_capabilities_recv(struct tevent_req *req) } NTSTATUS cli_set_unix_extensions_capabilities(struct cli_state *cli, - uint16 major, uint16 minor, - uint32 caplow, uint32 caphigh) + uint16_t major, uint16 minor, + uint32_t caplow, uint32 caphigh) { struct tevent_context *ev; struct tevent_req *req; @@ -432,7 +432,7 @@ NTSTATUS cli_get_fs_full_size_info(struct cli_state *cli, uint64_t *sectors_per_allocation_unit, uint64_t *bytes_per_sector) { - uint16 setup[1]; + uint16_t setup[1]; uint8_t param[2]; uint8_t *rdata = NULL; uint32_t rdata_count; @@ -476,8 +476,8 @@ fail: } NTSTATUS cli_get_posix_fs_info(struct cli_state *cli, - uint32 *optimal_transfer_size, - uint32 *block_size, + uint32_t *optimal_transfer_size, + uint32_t *block_size, uint64_t *total_blocks, uint64_t *blocks_available, uint64_t *user_blocks_available, @@ -485,7 +485,7 @@ NTSTATUS cli_get_posix_fs_info(struct cli_state *cli, uint64_t *free_file_nodes, uint64_t *fs_identifier) { - uint16 setup[1]; + uint16_t setup[1]; uint8_t param[2]; uint8_t *rdata = NULL; uint32_t rdata_count; @@ -748,8 +748,8 @@ NTSTATUS cli_force_encryption(struct cli_state *c, const char *password, const char *domain) { - uint16 major, minor; - uint32 caplow, caphigh; + uint16_t major, minor; + uint32_t caplow, caphigh; NTSTATUS status; if (!SERVER_HAS_UNIX_CIFS(c)) { diff --git a/source3/libsmb/clilist.c b/source3/libsmb/clilist.c index 3080fb883dd..2e5023916e7 100644 --- a/source3/libsmb/clilist.c +++ b/source3/libsmb/clilist.c @@ -56,7 +56,7 @@ static size_t interpret_long_filename(TALLOC_CTX *ctx, const char *p, const char *pdata_end, struct file_info *finfo, - uint32 *p_resume_key, + uint32_t *p_resume_key, DATA_BLOB *p_last_name_raw) { int len; @@ -479,7 +479,7 @@ static NTSTATUS cli_list_old_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx, } NTSTATUS cli_list_old(struct cli_state *cli, const char *mask, - uint16 attribute, + uint16_t attribute, NTSTATUS (*fn)(const char *, struct file_info *, const char *, void *), void *state) { @@ -929,7 +929,7 @@ NTSTATUS cli_list_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx, return NT_STATUS_OK; } -NTSTATUS cli_list(struct cli_state *cli, const char *mask, uint16 attribute, +NTSTATUS cli_list(struct cli_state *cli, const char *mask, uint16_t attribute, NTSTATUS (*fn)(const char *, struct file_info *, const char *, void *), void *state) { diff --git a/source3/libsmb/clirap.c b/source3/libsmb/clirap.c index 08f8ba2b6a9..dd2c30e2258 100644 --- a/source3/libsmb/clirap.c +++ b/source3/libsmb/clirap.c @@ -165,7 +165,7 @@ bool cli_NetWkstaUserLogon(struct cli_state *cli,char *user, char *workstation) Call a NetShareEnum - try and browse available connections on a host. ****************************************************************************/ -int cli_RNetShareEnum(struct cli_state *cli, void (*fn)(const char *, uint32, const char *, void *), void *state) +int cli_RNetShareEnum(struct cli_state *cli, void (*fn)(const char *, uint32_t, const char *, void *), void *state) { char *rparam = NULL; char *rdata = NULL; @@ -272,8 +272,8 @@ int cli_RNetShareEnum(struct cli_state *cli, void (*fn)(const char *, uint32, co the comment and a state pointer. ****************************************************************************/ -bool cli_NetServerEnum(struct cli_state *cli, char *workgroup, uint32 stype, - void (*fn)(const char *, uint32, const char *, void *), +bool cli_NetServerEnum(struct cli_state *cli, char *workgroup, uint32_t stype, + void (*fn)(const char *, uint32_t, const char *, void *), void *state) { char *rparam = NULL; @@ -284,7 +284,7 @@ bool cli_NetServerEnum(struct cli_state *cli, char *workgroup, uint32 stype, char param[1024]; int uLevel = 1; size_t len; - uint32 func = RAP_NetServerEnum2; + uint32_t func = RAP_NetServerEnum2; char *last_entry = NULL; int total_cnt = 0; int return_cnt = 0; @@ -626,7 +626,7 @@ NTSTATUS cli_qpathinfo1_recv(struct tevent_req *req, time_t *access_time, time_t *write_time, off_t *size, - uint16 *mode) + uint16_t *mode) { struct cli_qpathinfo1_state *state = tevent_req_data( req, struct cli_qpathinfo1_state); @@ -668,7 +668,7 @@ NTSTATUS cli_qpathinfo1(struct cli_state *cli, time_t *access_time, time_t *write_time, off_t *size, - uint16 *mode) + uint16_t *mode) { TALLOC_CTX *frame = talloc_stackframe(); struct tevent_context *ev; @@ -709,7 +709,7 @@ NTSTATUS cli_setpathinfo_basic(struct cli_state *cli, const char *fname, time_t access_time, time_t write_time, time_t change_time, - uint16 mode) + uint16_t mode) { unsigned int data_len = 0; char data[40]; @@ -802,7 +802,7 @@ NTSTATUS cli_qpathinfo2_recv(struct tevent_req *req, struct timespec *access_time, struct timespec *write_time, struct timespec *change_time, - off_t *size, uint16 *mode, + off_t *size, uint16_t *mode, SMB_INO_T *ino) { struct cli_qpathinfo2_state *state = tevent_req_data( @@ -842,7 +842,7 @@ NTSTATUS cli_qpathinfo2(struct cli_state *cli, const char *fname, struct timespec *access_time, struct timespec *write_time, struct timespec *change_time, - off_t *size, uint16 *mode, + off_t *size, uint16_t *mode, SMB_INO_T *ino) { TALLOC_CTX *frame = NULL; @@ -1138,7 +1138,7 @@ NTSTATUS cli_qfilename(struct cli_state *cli, uint16_t fnum, ****************************************************************************/ NTSTATUS cli_qfileinfo_basic(struct cli_state *cli, uint16_t fnum, - uint16 *mode, off_t *size, + uint16_t *mode, off_t *size, struct timespec *create_time, struct timespec *access_time, struct timespec *write_time, @@ -1255,7 +1255,7 @@ static void cli_qpathinfo_basic_done(struct tevent_req *subreq) } NTSTATUS cli_qpathinfo_basic_recv(struct tevent_req *req, - SMB_STRUCT_STAT *sbuf, uint32 *attributes) + SMB_STRUCT_STAT *sbuf, uint32_t *attributes) { struct cli_qpathinfo_basic_state *state = tevent_req_data( req, struct cli_qpathinfo_basic_state); @@ -1274,7 +1274,7 @@ NTSTATUS cli_qpathinfo_basic_recv(struct tevent_req *req, } NTSTATUS cli_qpathinfo_basic(struct cli_state *cli, const char *name, - SMB_STRUCT_STAT *sbuf, uint32 *attributes) + SMB_STRUCT_STAT *sbuf, uint32_t *attributes) { TALLOC_CTX *frame = NULL; struct tevent_context *ev; @@ -1420,7 +1420,7 @@ NTSTATUS cli_qpathinfo3(struct cli_state *cli, const char *fname, struct timespec *access_time, struct timespec *write_time, struct timespec *change_time, - off_t *size, uint16 *mode, + off_t *size, uint16_t *mode, SMB_INO_T *ino) { NTSTATUS status = NT_STATUS_OK; diff --git a/source3/libsmb/clirap.h b/source3/libsmb/clirap.h index 54f06b4e76c..a0d4d0609af 100644 --- a/source3/libsmb/clirap.h +++ b/source3/libsmb/clirap.h @@ -35,9 +35,9 @@ bool cli_api(struct cli_state *cli, char **rparam, unsigned int *rprcnt, char **rdata, unsigned int *rdrcnt); bool cli_NetWkstaUserLogon(struct cli_state *cli,char *user, char *workstation); -int cli_RNetShareEnum(struct cli_state *cli, void (*fn)(const char *, uint32, const char *, void *), void *state); -bool cli_NetServerEnum(struct cli_state *cli, char *workgroup, uint32 stype, - void (*fn)(const char *, uint32, const char *, void *), +int cli_RNetShareEnum(struct cli_state *cli, void (*fn)(const char *, uint32_t, const char *, void *), void *state); +bool cli_NetServerEnum(struct cli_state *cli, char *workgroup, uint32_t stype, + void (*fn)(const char *, uint32_t, const char *, void *), void *state); bool cli_oem_change_password(struct cli_state *cli, const char *user, const char *new_password, const char *old_password); @@ -50,20 +50,20 @@ NTSTATUS cli_qpathinfo1_recv(struct tevent_req *req, time_t *access_time, time_t *write_time, off_t *size, - uint16 *mode); + uint16_t *mode); NTSTATUS cli_qpathinfo1(struct cli_state *cli, const char *fname, time_t *change_time, time_t *access_time, time_t *write_time, off_t *size, - uint16 *mode); + uint16_t *mode); NTSTATUS cli_setpathinfo_basic(struct cli_state *cli, const char *fname, time_t create_time, time_t access_time, time_t write_time, time_t change_time, - uint16 mode); + uint16_t mode); struct tevent_req *cli_qpathinfo2_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, struct cli_state *cli, @@ -73,21 +73,21 @@ NTSTATUS cli_qpathinfo2_recv(struct tevent_req *req, struct timespec *access_time, struct timespec *write_time, struct timespec *change_time, - off_t *size, uint16 *mode, + off_t *size, uint16_t *mode, SMB_INO_T *ino); NTSTATUS cli_qpathinfo2(struct cli_state *cli, const char *fname, struct timespec *create_time, struct timespec *access_time, struct timespec *write_time, struct timespec *change_time, - off_t *size, uint16 *mode, + off_t *size, uint16_t *mode, SMB_INO_T *ino); NTSTATUS cli_qpathinfo3(struct cli_state *cli, const char *fname, struct timespec *create_time, struct timespec *access_time, struct timespec *write_time, struct timespec *change_time, - off_t *size, uint16 *mode, + off_t *size, uint16_t *mode, SMB_INO_T *ino); struct tevent_req *cli_qpathinfo_streams_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, @@ -108,7 +108,7 @@ bool parse_streams_blob(TALLOC_CTX *mem_ctx, const uint8_t *rdata, NTSTATUS cli_qfilename(struct cli_state *cli, uint16_t fnum, TALLOC_CTX *mem_ctx, char **name); NTSTATUS cli_qfileinfo_basic(struct cli_state *cli, uint16_t fnum, - uint16 *mode, off_t *size, + uint16_t *mode, off_t *size, struct timespec *create_time, struct timespec *access_time, struct timespec *write_time, @@ -119,9 +119,9 @@ struct tevent_req *cli_qpathinfo_basic_send(TALLOC_CTX *mem_ctx, struct cli_state *cli, const char *fname); NTSTATUS cli_qpathinfo_basic_recv(struct tevent_req *req, - SMB_STRUCT_STAT *sbuf, uint32 *attributes); + SMB_STRUCT_STAT *sbuf, uint32_t *attributes); NTSTATUS cli_qpathinfo_basic(struct cli_state *cli, const char *name, - SMB_STRUCT_STAT *sbuf, uint32 *attributes); + SMB_STRUCT_STAT *sbuf, uint32_t *attributes); NTSTATUS cli_qpathinfo_standard(struct cli_state *cli, const char *fname, uint64_t *allocated, uint64_t *size, uint32_t *nlinks, @@ -191,31 +191,31 @@ int cli_RNetUserEnum(struct cli_state *cli, void (*fn)(const char *, const char int cli_RNetUserEnum0(struct cli_state *cli, void (*fn)(const char *, void *), void *state); -int cli_NetFileClose(struct cli_state *cli, uint32 file_id ); -int cli_NetFileGetInfo(struct cli_state *cli, uint32 file_id, void (*fn)(const char *, const char *, uint16, uint16, uint32)); +int cli_NetFileClose(struct cli_state *cli, uint32_t file_id ); +int cli_NetFileGetInfo(struct cli_state *cli, uint32_t file_id, void (*fn)(const char *, const char *, uint16_t, uint16_t, uint32_t)); int cli_NetFileEnum(struct cli_state *cli, const char * user, const char * base_path, - void (*fn)(const char *, const char *, uint16, uint16, - uint32)); + void (*fn)(const char *, const char *, uint16_t, uint16_t, + uint32_t)); int cli_NetShareAdd(struct cli_state *cli, struct rap_share_info_2 * sinfo ); int cli_NetShareDelete(struct cli_state *cli, const char * share_name ); bool cli_get_pdc_name(struct cli_state *cli, const char *workgroup, char **pdc_name); bool cli_get_server_domain(struct cli_state *cli); -bool cli_get_server_type(struct cli_state *cli, uint32 *pstype); +bool cli_get_server_type(struct cli_state *cli, uint32_t *pstype); bool cli_get_server_name(TALLOC_CTX *mem_ctx, struct cli_state *cli, char **servername); -bool cli_ns_check_server_type(struct cli_state *cli, char *workgroup, uint32 stype); +bool cli_ns_check_server_type(struct cli_state *cli, char *workgroup, uint32_t stype); bool cli_NetWkstaUserLogoff(struct cli_state *cli, const char *user, const char *workstation); int cli_NetPrintQEnum(struct cli_state *cli, - void (*qfn)(const char*,uint16,uint16,uint16,const char*,const char*,const char*,const char*,const char*,uint16,uint16), - void (*jfn)(uint16,const char*,const char*,const char*,const char*,uint16,uint16,const char*,unsigned int,unsigned int,const char*)); + void (*qfn)(const char*,uint16_t,uint16_t,uint16_t,const char*,const char*,const char*,const char*,const char*,uint16_t,uint16_t), + void (*jfn)(uint16_t,const char*,const char*,const char*,const char*,uint16_t,uint16_t,const char*,unsigned int,unsigned int,const char*)); int cli_NetPrintQGetInfo(struct cli_state *cli, const char *printer, - void (*qfn)(const char*,uint16,uint16,uint16,const char*,const char*,const char*,const char*,const char*,uint16,uint16), - void (*jfn)(uint16,const char*,const char*,const char*,const char*,uint16,uint16,const char*,unsigned int,unsigned int,const char*)); + void (*qfn)(const char*,uint16_t,uint16_t,uint16_t,const char*,const char*,const char*,const char*,const char*,uint16_t,uint16_t), + void (*jfn)(uint16_t,const char*,const char*,const char*,const char*,uint16_t,uint16_t,const char*,unsigned int,unsigned int,const char*)); int cli_RNetServiceEnum(struct cli_state *cli, void (*fn)(const char *, const char *, void *), void *state); -int cli_NetSessionEnum(struct cli_state *cli, void (*fn)(char *, char *, uint16, uint16, uint16, unsigned int, unsigned int, unsigned int, char *)); +int cli_NetSessionEnum(struct cli_state *cli, void (*fn)(char *, char *, uint16_t, uint16_t, uint16_t, unsigned int, unsigned int, unsigned int, char *)); int cli_NetSessionGetInfo(struct cli_state *cli, const char *workstation, - void (*fn)(const char *, const char *, uint16, uint16, uint16, unsigned int, unsigned int, unsigned int, const char *)); + void (*fn)(const char *, const char *, uint16_t, uint16_t, uint16_t, unsigned int, unsigned int, unsigned int, const char *)); int cli_NetSessionDel(struct cli_state *cli, const char *workstation); int cli_NetConnectionEnum(struct cli_state *cli, const char *qualifier, void (*fn)(uint16_t conid, uint16_t contype, diff --git a/source3/libsmb/clirap2.c b/source3/libsmb/clirap2.c index 457a82ee116..931bc237f9a 100644 --- a/source3/libsmb/clirap2.c +++ b/source3/libsmb/clirap2.c @@ -218,7 +218,7 @@ static size_t rap_getstringp(TALLOC_CTX *ctx, char *p, char **dest, char *r, uin return 4; } -static char *make_header(char *param, uint16 apinum, const char *reqfmt, const char *datafmt) +static char *make_header(char *param, uint16_t apinum, const char *reqfmt, const char *datafmt) { PUTWORD(param,apinum); if (reqfmt) @@ -1097,7 +1097,7 @@ int cli_RNetUserEnum0(struct cli_state *cli, Call a NetFileClose2 - close open file on another session to server. ****************************************************************************/ -int cli_NetFileClose(struct cli_state *cli, uint32 file_id ) +int cli_NetFileClose(struct cli_state *cli, uint32_t file_id ) { char *rparam = NULL; char *rdata = NULL; @@ -1145,7 +1145,7 @@ int cli_NetFileClose(struct cli_state *cli, uint32 file_id ) workstation. ****************************************************************************/ -int cli_NetFileGetInfo(struct cli_state *cli, uint32 file_id, void (*fn)(const char *, const char *, uint16, uint16, uint32)) +int cli_NetFileGetInfo(struct cli_state *cli, uint32_t file_id, void (*fn)(const char *, const char *, uint16_t, uint16_t, uint32_t)) { char *rparam = NULL; char *rdata = NULL; @@ -1245,8 +1245,8 @@ int cli_NetFileGetInfo(struct cli_state *cli, uint32 file_id, void (*fn)(const c int cli_NetFileEnum(struct cli_state *cli, const char * user, const char * base_path, - void (*fn)(const char *, const char *, uint16, uint16, - uint32)) + void (*fn)(const char *, const char *, uint16_t, uint16_t, + uint32_t)) { char *rparam = NULL; char *rdata = NULL; @@ -1636,7 +1636,7 @@ bool cli_get_server_domain(struct cli_state *cli) * * Parameters: * cli - pointer to cli_state structure -* pstype - pointer to uint32 to contain returned server type +* pstype - pointer to uint32_t to contain returned server type * * Returns: * True - success @@ -1646,7 +1646,7 @@ bool cli_get_server_domain(struct cli_state *cli) * ************************************************************************/ -bool cli_get_server_type(struct cli_state *cli, uint32 *pstype) +bool cli_get_server_type(struct cli_state *cli, uint32_t *pstype) { char *rparam = NULL; char *rdata = NULL; @@ -1775,7 +1775,7 @@ bool cli_get_server_name(TALLOC_CTX *mem_ctx, struct cli_state *cli, * ************************************************************************/ -bool cli_ns_check_server_type(struct cli_state *cli, char *workgroup, uint32 stype) +bool cli_ns_check_server_type(struct cli_state *cli, char *workgroup, uint32_t stype) { char *rparam = NULL; char *rdata = NULL; @@ -1910,8 +1910,8 @@ bool cli_NetWkstaUserLogoff(struct cli_state *cli, const char *user, const char } int cli_NetPrintQEnum(struct cli_state *cli, - void (*qfn)(const char*,uint16,uint16,uint16,const char*,const char*,const char*,const char*,const char*,uint16,uint16), - void (*jfn)(uint16,const char*,const char*,const char*,const char*,uint16,uint16,const char*,unsigned int,unsigned int,const char*)) + void (*qfn)(const char*,uint16_t,uint16_t,uint16_t,const char*,const char*,const char*,const char*,const char*,uint16_t,uint16_t), + void (*jfn)(uint16_t,const char*,const char*,const char*,const char*,uint16_t,uint16_t,const char*,unsigned int,unsigned int,const char*)) { char param[WORDSIZE /* api number */ +sizeof(RAP_NetPrintQEnum_REQ) /* req string */ @@ -2018,7 +2018,7 @@ int cli_NetPrintQEnum(struct cli_state *cli, if (jobcount) { int j; for (j=0;j<jobcount;j++) { - uint16 jid = 0, pos = 0, fsstatus = 0; + uint16_t jid = 0, pos = 0, fsstatus = 0; char ownername[RAP_USERNAME_LEN]; char notifyname[RAP_MACHNAME_LEN]; char datatype[RAP_DATATYPE_LEN]; @@ -2086,8 +2086,8 @@ int cli_NetPrintQEnum(struct cli_state *cli, } int cli_NetPrintQGetInfo(struct cli_state *cli, const char *printer, - void (*qfn)(const char*,uint16,uint16,uint16,const char*,const char*,const char*,const char*,const char*,uint16,uint16), - void (*jfn)(uint16,const char*,const char*,const char*,const char*,uint16,uint16,const char*,unsigned int,unsigned int,const char*)) + void (*qfn)(const char*,uint16_t,uint16_t,uint16_t,const char*,const char*,const char*,const char*,const char*,uint16_t,uint16_t), + void (*jfn)(uint16_t,const char*,const char*,const char*,const char*,uint16_t,uint16_t,const char*,unsigned int,unsigned int,const char*)) { char param[WORDSIZE /* api number */ +sizeof(RAP_NetPrintQGetInfo_REQ) /* req string */ @@ -2347,7 +2347,7 @@ int cli_RNetServiceEnum(struct cli_state *cli, void (*fn)(const char *, const ch Call a NetSessionEnum - list workstations with sessions to an SMB server. ****************************************************************************/ -int cli_NetSessionEnum(struct cli_state *cli, void (*fn)(char *, char *, uint16, uint16, uint16, unsigned int, unsigned int, unsigned int, char *)) +int cli_NetSessionEnum(struct cli_state *cli, void (*fn)(char *, char *, uint16_t, uint16_t, uint16_t, unsigned int, unsigned int, unsigned int, char *)) { char param[WORDSIZE /* api number */ +sizeof(RAP_NetSessionEnum_REQ) /* parm string */ @@ -2447,7 +2447,7 @@ int cli_NetSessionEnum(struct cli_state *cli, void (*fn)(char *, char *, uint16, ****************************************************************************/ int cli_NetSessionGetInfo(struct cli_state *cli, const char *workstation, - void (*fn)(const char *, const char *, uint16, uint16, uint16, unsigned int, unsigned int, unsigned int, const char *)) + void (*fn)(const char *, const char *, uint16_t, uint16_t, uint16_t, unsigned int, unsigned int, unsigned int, const char *)) { char param[WORDSIZE /* api number */ +sizeof(RAP_NetSessionGetInfo_REQ) /* req string */ diff --git a/source3/libsmb/clisecdesc.c b/source3/libsmb/clisecdesc.c index 986610fb785..c11e4b322ef 100644 --- a/source3/libsmb/clisecdesc.c +++ b/source3/libsmb/clisecdesc.c @@ -62,7 +62,7 @@ NTSTATUS cli_query_security_descriptor(struct cli_state *cli, goto cleanup; } - status = unmarshall_sec_desc(mem_ctx, (uint8 *)rdata, rdata_count, + status = unmarshall_sec_desc(mem_ctx, (uint8_t *)rdata, rdata_count, &lsd); if (!NT_STATUS_IS_OK(status)) { DEBUG(10, ("unmarshall_sec_desc failed: %s\n", @@ -100,7 +100,7 @@ NTSTATUS cli_set_security_descriptor(struct cli_state *cli, const struct security_descriptor *sd) { uint8_t param[8]; - uint8 *data; + uint8_t *data; size_t len; NTSTATUS status; diff --git a/source3/libsmb/libsmb_dir.c b/source3/libsmb/libsmb_dir.c index 3a07f118b0c..d131c30c772 100644 --- a/source3/libsmb/libsmb_dir.c +++ b/source3/libsmb/libsmb_dir.c @@ -60,7 +60,7 @@ static int add_dirent(SMBCFILE *dir, const char *name, const char *comment, - uint32 type) + uint32_t type) { struct smbc_dirent *dirent; int size; @@ -138,7 +138,7 @@ add_dirent(SMBCFILE *dir, static void list_unique_wg_fn(const char *name, - uint32 type, + uint32_t type, const char *comment, void *state) { @@ -183,7 +183,7 @@ list_unique_wg_fn(const char *name, static void list_fn(const char *name, - uint32 type, + uint32_t type, const char *comment, void *state) { @@ -257,15 +257,15 @@ dir_list_fn(const char *mnt, static int net_share_enum_rpc(struct cli_state *cli, void (*fn)(const char *name, - uint32 type, + uint32_t type, const char *comment, void *state), void *state) { int i; WERROR result; - uint32 preferred_len = 0xffffffff; - uint32 type; + uint32_t preferred_len = 0xffffffff; + uint32_t type; struct srvsvc_NetShareInfoCtr info_ctr; struct srvsvc_NetShareCtr1 ctr1; fstring name = ""; @@ -377,7 +377,7 @@ SMBC_opendir_ctx(SMBCCTX *context, char *options = NULL; char *workgroup = NULL; char *path = NULL; - uint16 mode; + uint16_t mode; uint16_t port = 0; char *p = NULL; SMBCSRV *srv = NULL; @@ -1562,7 +1562,7 @@ SMBC_chmod_ctx(SMBCCTX *context, char *targetpath = NULL; struct cli_state *targetcli = NULL; char *path = NULL; - uint16 mode; + uint16_t mode; uint16_t port = 0; TALLOC_CTX *frame = talloc_stackframe(); NTSTATUS status; @@ -1832,7 +1832,7 @@ SMBC_unlink_ctx(SMBCCTX *context, int saverr = errno; off_t size = 0; - uint16 mode = 0; + uint16_t mode = 0; struct timespec write_time_ts; struct timespec access_time_ts; struct timespec change_time_ts; diff --git a/source3/libsmb/libsmb_file.c b/source3/libsmb/libsmb_file.c index 8fb7a2e67ec..11d6d827809 100644 --- a/source3/libsmb/libsmb_file.c +++ b/source3/libsmb/libsmb_file.c @@ -496,7 +496,7 @@ bool SMBC_getatr(SMBCCTX * context, SMBCSRV *srv, const char *path, - uint16 *mode, + uint16_t *mode, off_t *size, struct timespec *create_time_ts, struct timespec *access_time_ts, @@ -626,7 +626,7 @@ SMBC_setatr(SMBCCTX * context, SMBCSRV *srv, char *path, time_t access_time, time_t write_time, time_t change_time, - uint16 mode) + uint16_t mode) { uint16_t fd; int ret; @@ -681,7 +681,7 @@ SMBC_setatr(SMBCCTX * context, SMBCSRV *srv, char *path, * cli_setatr() for that, and with only this parameter, it * seems to work on win98. */ - if (ret && mode != (uint16) -1) { + if (ret && mode != (uint16_t) -1) { ret = NT_STATUS_IS_OK(cli_setatr(srv->cli, path, mode, 0)); } diff --git a/source3/libsmb/libsmb_misc.c b/source3/libsmb/libsmb_misc.c index 98739c69ef4..1d874c74cd8 100644 --- a/source3/libsmb/libsmb_misc.c +++ b/source3/libsmb/libsmb_misc.c @@ -53,8 +53,8 @@ SMBC_errno(SMBCCTX *context, int ret = cli_errno(c); if (cli_is_dos_error(c)) { - uint8 eclass; - uint32 ecode; + uint8_t eclass; + uint32_t ecode; cli_dos_error(c, &eclass, &ecode); diff --git a/source3/libsmb/libsmb_server.c b/source3/libsmb/libsmb_server.c index d6c25884ef0..07d51ea00cb 100644 --- a/source3/libsmb/libsmb_server.c +++ b/source3/libsmb/libsmb_server.c @@ -267,7 +267,7 @@ SMBC_server_internal(TALLOC_CTX *ctx, struct cli_state *c = NULL; const char *server_n = server; int is_ipc = (share != NULL && strcmp(share, "IPC$") == 0); - uint32 fs_attrs = 0; + uint32_t fs_attrs = 0; const char *username_used; NTSTATUS status; char *newserver, *newshare; diff --git a/source3/libsmb/libsmb_stat.c b/source3/libsmb/libsmb_stat.c index 3c895cefd3e..4191ad6d215 100644 --- a/source3/libsmb/libsmb_stat.c +++ b/source3/libsmb/libsmb_stat.c @@ -119,7 +119,7 @@ SMBC_stat_ctx(SMBCCTX *context, struct timespec access_time_ts; struct timespec change_time_ts; off_t size = 0; - uint16 mode = 0; + uint16_t mode = 0; uint16_t port = 0; SMB_INO_T ino = 0; TALLOC_CTX *frame = talloc_stackframe(); @@ -207,7 +207,7 @@ SMBC_fstat_ctx(SMBCCTX *context, struct timespec access_time_ts; struct timespec write_time_ts; off_t size; - uint16 mode; + uint16_t mode; char *server = NULL; char *share = NULL; char *user = NULL; @@ -368,7 +368,7 @@ SMBC_fstatvfs_ctx(SMBCCTX *context, struct statvfs *st) { unsigned long flags = 0; - uint32 fs_attrs = 0; + uint32_t fs_attrs = 0; struct cli_state *cli = file->srv->cli; struct smbXcli_tcon *tcon; TALLOC_CTX *frame = talloc_stackframe(); @@ -424,8 +424,8 @@ SMBC_fstatvfs_ctx(SMBCCTX *context, flags |= SMBC_VFS_FEATURE_NO_UNIXCIFS; } else { - uint32 optimal_transfer_size; - uint32 block_size; + uint32_t optimal_transfer_size; + uint32_t block_size; uint64_t total_blocks; uint64_t blocks_available; uint64_t user_blocks_available; diff --git a/source3/libsmb/libsmb_xattr.c b/source3/libsmb/libsmb_xattr.c index 9f7bea8da11..8c23a8f87a6 100644 --- a/source3/libsmb/libsmb_xattr.c +++ b/source3/libsmb/libsmb_xattr.c @@ -146,7 +146,7 @@ ace_compare(struct security_ace *ace1, static void sort_acl(struct security_acl *the_acl) { - uint32 i; + uint32_t i; if (!the_acl) return; TYPESAFE_QSORT(the_acl->aces, the_acl->num_aces, ace_compare); @@ -272,7 +272,7 @@ parse_ace(struct cli_state *ipc_cli, const struct perm_value *v; struct perm_value { const char perm[7]; - uint32 mask; + uint32_t mask; }; TALLOC_CTX *frame = talloc_stackframe(); @@ -558,7 +558,7 @@ dos_attr_query(SMBCCTX *context, struct timespec access_time_ts; struct timespec change_time_ts; off_t size = 0; - uint16 mode = 0; + uint16_t mode = 0; SMB_INO_T inode = 0; DOS_ATTR_DESC *ret; @@ -708,7 +708,7 @@ cacl_get(SMBCCTX *context, char *buf, int bufsize) { - uint32 i; + uint32_t i; int n = 0; int n_used; bool all; @@ -746,7 +746,7 @@ cacl_get(SMBCCTX *context, time_t access_time = (time_t)0; time_t change_time = (time_t)0; off_t size = 0; - uint16 mode = 0; + uint16_t mode = 0; SMB_INO_T ino = 0; struct cli_state *cli = srv->cli; struct { @@ -1515,7 +1515,7 @@ cacl_set(SMBCCTX *context, struct security_acl *dacl = NULL; struct dom_sid *owner_sid = NULL; struct dom_sid *group_sid = NULL; - uint32 i, j; + uint32_t i, j; size_t sd_size; int ret = 0; char *p; @@ -1595,7 +1595,7 @@ cacl_set(SMBCCTX *context, for (j=0;old->dacl && j<old->dacl->num_aces;j++) { if (security_ace_equal(&sd->dacl->aces[i], &old->dacl->aces[j])) { - uint32 k; + uint32_t k; for (k=j; k<old->dacl->num_aces-1;k++) { old->dacl->aces[k] = old->dacl->aces[k+1]; diff --git a/source3/libsmb/namequery.c b/source3/libsmb/namequery.c index 68cac3fa3d8..8138296f1e3 100644 --- a/source3/libsmb/namequery.c +++ b/source3/libsmb/namequery.c @@ -240,9 +240,9 @@ static struct in_addr my_socket_addr_v4(void) static int generate_trn_id(void) { - uint16 id; + uint16_t id; - generate_random_buffer((uint8 *)&id, sizeof(id)); + generate_random_buffer((uint8_t *)&id, sizeof(id)); return id % (unsigned)0x7FFF; } diff --git a/source3/libsmb/nmblib.c b/source3/libsmb/nmblib.c index 4adc3da5fab..8feb029b05e 100644 --- a/source3/libsmb/nmblib.c +++ b/source3/libsmb/nmblib.c @@ -1334,7 +1334,7 @@ static unsigned char *name_ptr(unsigned char *buf, size_t buf_len, unsigned int c = *(unsigned char *)(buf+ofs); if ((c & 0xC0) == 0xC0) { - uint16 l = 0; + uint16_t l = 0; if (ofs > buf_len - 1) { return NULL; diff --git a/source3/libsmb/proto.h b/source3/libsmb/proto.h index f392a35f4c3..a837bef1a41 100644 --- a/source3/libsmb/proto.h +++ b/source3/libsmb/proto.h @@ -99,7 +99,7 @@ NTSTATUS cli_full_connection(struct cli_state **output_cli, int signing_state); NTSTATUS cli_raw_tcon(struct cli_state *cli, const char *service, const char *pass, const char *dev, - uint16 *max_xmit, uint16 *tid); + uint16_t *max_xmit, uint16_t *tid); struct cli_state *get_ipc_connect(char *server, struct sockaddr_storage *server_ss, const struct user_auth_info *user_info); @@ -172,7 +172,7 @@ void cli_nt_pipes_close(struct cli_state *cli); void cli_shutdown(struct cli_state *cli); const char *cli_state_remote_realm(struct cli_state *cli); uint16_t cli_state_get_vc_num(struct cli_state *cli); -uint16 cli_setpid(struct cli_state *cli, uint16 pid); +uint16_t cli_setpid(struct cli_state *cli, uint16_t pid); uint16_t cli_getpid(struct cli_state *cli); bool cli_state_has_tcon(struct cli_state *cli); uint16_t cli_state_get_tid(struct cli_state *cli); @@ -200,7 +200,7 @@ NTSTATUS cli_smb(TALLOC_CTX *mem_ctx, struct cli_state *cli, const char *cli_errstr(struct cli_state *cli); NTSTATUS cli_nt_error(struct cli_state *cli); -void cli_dos_error(struct cli_state *cli, uint8 *eclass, uint32 *ecode); +void cli_dos_error(struct cli_state *cli, uint8_t *eclass, uint32_t *ecode); int cli_errno(struct cli_state *cli); bool cli_is_error(struct cli_state *cli); bool cli_is_nt_error(struct cli_state *cli); @@ -628,16 +628,16 @@ NTSTATUS cli_unix_extensions_version_recv(struct tevent_req *req, uint16_t *pmajor, uint16_t *pminor, uint32_t *pcaplow, uint32_t *pcaphigh); -NTSTATUS cli_unix_extensions_version(struct cli_state *cli, uint16 *pmajor, - uint16 *pminor, uint32 *pcaplow, - uint32 *pcaphigh); +NTSTATUS cli_unix_extensions_version(struct cli_state *cli, uint16_t *pmajor, + uint16_t *pminor, uint32_t *pcaplow, + uint32_t *pcaphigh); struct tevent_req *cli_set_unix_extensions_capabilities_send( TALLOC_CTX *mem_ctx, struct tevent_context *ev, struct cli_state *cli, uint16_t major, uint16_t minor, uint32_t caplow, uint32_t caphigh); NTSTATUS cli_set_unix_extensions_capabilities_recv(struct tevent_req *req); NTSTATUS cli_set_unix_extensions_capabilities(struct cli_state *cli, - uint16 major, uint16 minor, - uint32 caplow, uint32 caphigh); + uint16_t major, uint16_t minor, + uint32_t caplow, uint32 caphigh); struct tevent_req *cli_get_fs_attr_info_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, struct cli_state *cli); @@ -645,7 +645,7 @@ NTSTATUS cli_get_fs_attr_info_recv(struct tevent_req *req, uint32_t *fs_attr); NTSTATUS cli_get_fs_attr_info(struct cli_state *cli, uint32_t *fs_attr); NTSTATUS cli_get_fs_volume_info(struct cli_state *cli, TALLOC_CTX *mem_ctx, char **volume_name, - uint32 *pserial_number, time_t *pdate); + uint32_t *pserial_number, time_t *pdate); NTSTATUS cli_get_fs_full_size_info(struct cli_state *cli, uint64_t *total_allocation_units, uint64_t *caller_allocation_units, @@ -653,8 +653,8 @@ NTSTATUS cli_get_fs_full_size_info(struct cli_state *cli, uint64_t *sectors_per_allocation_unit, uint64_t *bytes_per_sector); NTSTATUS cli_get_posix_fs_info(struct cli_state *cli, - uint32 *optimal_transfer_size, - uint32 *block_size, + uint32_t *optimal_transfer_size, + uint32_t *block_size, uint64_t *total_blocks, uint64_t *blocks_available, uint64_t *user_blocks_available, @@ -673,7 +673,7 @@ NTSTATUS cli_force_encryption(struct cli_state *c, /* The following definitions come from libsmb/clilist.c */ -NTSTATUS cli_list_old(struct cli_state *cli,const char *Mask,uint16 attribute, +NTSTATUS cli_list_old(struct cli_state *cli,const char *Mask,uint16_t attribute, NTSTATUS (*fn)(const char *, struct file_info *, const char *, void *), void *state); NTSTATUS cli_list_trans(struct cli_state *cli, const char *mask, @@ -689,7 +689,7 @@ struct tevent_req *cli_list_send(TALLOC_CTX *mem_ctx, uint16_t info_level); NTSTATUS cli_list_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx, struct file_info **finfo, size_t *num_finfo); -NTSTATUS cli_list(struct cli_state *cli,const char *Mask,uint16 attribute, +NTSTATUS cli_list(struct cli_state *cli,const char *Mask,uint16_t attribute, NTSTATUS (*fn)(const char *, struct file_info *, const char *, void *), void *state); diff --git a/source3/libsmb/samlogon_cache.c b/source3/libsmb/samlogon_cache.c index 4e50c786882..c408082e806 100644 --- a/source3/libsmb/samlogon_cache.c +++ b/source3/libsmb/samlogon_cache.c @@ -266,7 +266,7 @@ struct netr_SamInfo3 *netsamlogon_cache_get(TALLOC_CTX *mem_ctx, const struct do --jerry */ { time_t now = time(NULL); - uint32 time_diff; + uint32_t time_diff; /* is the entry expired? */ time_diff = now - t; diff --git a/source3/libsmb/smb_share_modes.c b/source3/libsmb/smb_share_modes.c index d42ebc61400..37d599a1704 100644 --- a/source3/libsmb/smb_share_modes.c +++ b/source3/libsmb/smb_share_modes.c @@ -59,7 +59,7 @@ struct locking_data { int num_share_mode_entries; struct timespec old_write_time; struct timespec changed_write_time; - uint32 num_delete_token_entries; + uint32_t num_delete_token_entries; } s; struct share_mode_entry dummy; /* Needed for alignment. */ } u; @@ -144,7 +144,7 @@ static TDB_DATA get_locking_key(struct locking_key *lk, uint64_t dev, lk->dev = (SMB_DEV_T)dev; lk->inode = (SMB_INO_T)ino; lk->extid = extid; - ld.dptr = (uint8 *)lk; + ld.dptr = (uint8_t *)lk; ld.dsize = sizeof(*lk); return ld; } @@ -211,7 +211,7 @@ static void create_share_mode_entry(struct share_mode_entry *out, out->id.devid = in->dev; out->id.inode = in->ino; out->id.extid = in->extid; - out->uid = (uint32)geteuid(); + out->uid = (uint32_t)geteuid(); out->flags = 0; out->name_hash = name_hash; } @@ -343,7 +343,7 @@ int smb_create_share_mode_entry_ex(struct smbdb_ctx *db_ctx, int orig_num_share_modes = 0; struct locking_data *ld = NULL; /* internal samba db state. */ struct share_mode_entry *shares = NULL; - uint8 *new_data_p = NULL; + uint8_t *new_data_p = NULL; size_t new_data_size = 0; int err = 0; uint32_t name_hash = smb_name_hash(sharepath, filename, &err); @@ -355,7 +355,7 @@ int smb_create_share_mode_entry_ex(struct smbdb_ctx *db_ctx, db_data = tdb_fetch(db_ctx->smb_tdb, locking_key); if (!db_data.dptr) { /* We must create the entry. */ - db_data.dptr = (uint8 *)malloc( + db_data.dptr = (uint8_t *)malloc( sizeof(struct locking_data) + sizeof(struct share_mode_entry) + strlen(sharepath) + 1 + @@ -390,7 +390,7 @@ int smb_create_share_mode_entry_ex(struct smbdb_ctx *db_ctx, } /* Entry exists, we must add a new entry. */ - new_data_p = (uint8 *)malloc( + new_data_p = (uint8_t *)malloc( db_data.dsize + sizeof(struct share_mode_entry)); if (!new_data_p) { free(db_data.dptr); @@ -464,10 +464,10 @@ int smb_delete_share_mode_entry(struct smbdb_ctx *db_ctx, int orig_num_share_modes = 0; struct locking_data *ld = NULL; /* internal samba db state. */ struct share_mode_entry *shares = NULL; - uint8 *new_data_p = NULL; + uint8_t *new_data_p = NULL; size_t remaining_size = 0; size_t i, num_share_modes; - const uint8 *remaining_ptr = NULL; + const uint8_t *remaining_ptr = NULL; db_data = tdb_fetch(db_ctx->smb_tdb, locking_key); if (!db_data.dptr) { @@ -491,7 +491,7 @@ int smb_delete_share_mode_entry(struct smbdb_ctx *db_ctx, } /* More than one - allocate a new record minus the one we'll delete. */ - new_data_p = (uint8 *)malloc( + new_data_p = (uint8_t *)malloc( db_data.dsize - sizeof(struct share_mode_entry)); if (!new_data_p) { free(db_data.dptr); diff --git a/source3/libsmb/smbsock_connect.c b/source3/libsmb/smbsock_connect.c index 403750d7192..92abc38baef 100644 --- a/source3/libsmb/smbsock_connect.c +++ b/source3/libsmb/smbsock_connect.c @@ -29,7 +29,7 @@ struct cli_session_request_state { struct tevent_context *ev; int sock; - uint32 len_hdr; + uint32_t len_hdr; struct iovec iov[3]; uint8_t nb_session_response; }; |