summaryrefslogtreecommitdiff
path: root/source/include/proto.h
diff options
context:
space:
mode:
Diffstat (limited to 'source/include/proto.h')
-rw-r--r--source/include/proto.h46
1 files changed, 25 insertions, 21 deletions
diff --git a/source/include/proto.h b/source/include/proto.h
index 329903f787e..d68853b5e6d 100644
--- a/source/include/proto.h
+++ b/source/include/proto.h
@@ -198,6 +198,10 @@ int sys_ftruncate(int fd, SMB_OFF_T offset);
SMB_OFF_T sys_lseek(int fd, SMB_OFF_T offset, int whence);
int sys_fseek(FILE *fp, SMB_OFF_T offset, int whence);
SMB_OFF_T sys_ftell(FILE *fp);
+int sys_creat(const char *path, mode_t mode);
+int sys_open(const char *path, int oflag, mode_t mode);
+FILE *sys_fopen(const char *path, const char *type);
+void *sys_mmap(void *addr, size_t len, int prot, int flags, int fd, SMB_OFF_T offset);
int dos_unlink(char *fname);
int dos_open(char *fname,int flags,mode_t mode);
DIR *dos_opendir(char *dname);
@@ -383,35 +387,35 @@ char *client_addr(int fd);
/*The following definitions come from lib/util_str.c */
void set_first_token(char *ptr);
-BOOL next_token(char **ptr,char *buff,char *sep, int bufsize);
+BOOL next_token(char **ptr,char *buff,char *sep, size_t bufsize);
char **toktocliplist(int *ctok, char *sep);
int StrCaseCmp(const char *s, const char *t);
-int StrnCaseCmp(char *s, char *t, int n);
+int StrnCaseCmp(const char *s, const char *t, size_t n);
BOOL strequal(const char *s1, const char *s2);
-BOOL strnequal(char *s1,char *s2,int n);
-BOOL strcsequal(char *s1,char *s2);
+BOOL strnequal(const char *s1,const char *s2,size_t n);
+BOOL strcsequal(const char *s1,const char *s2);
void strlower(char *s);
void strupper(char *s);
void strnorm(char *s);
BOOL strisnormal(char *s);
void string_replace(char *s,char oldc,char newc);
-char *skip_string(char *buf,int n);
-size_t str_charnum(char *s);
-BOOL trim_string(char *s,char *front,char *back);
-BOOL strhasupper(char *s);
-BOOL strhaslower(char *s);
-int count_chars(char *s,char c);
-char *safe_strcpy(char *dest,const char *src, int maxlength);
-char *safe_strcat(char *dest, char *src, int maxlength);
-char *StrCpy(char *dest,char *src);
-char *StrnCpy(char *dest,const char *src,int n);
-char *strncpyn(char *dest, const char *src,int n, char c);
-int strhex_to_str(char *p, int len, const char *strhex);
+char *skip_string(const char *buf,size_t n);
+size_t str_charnum(const char *s);
+BOOL trim_string(char *s,const char *front,const char *back);
+BOOL strhasupper(const char *s);
+BOOL strhaslower(const char *s);
+size_t count_chars(const char *s,char c);
+char *safe_strcpy(char *dest,const char *src, size_t maxlength);
+char *safe_strcat(char *dest, const char *src, size_t maxlength);
+char *StrCpy(char *dest,const char *src);
+char *StrnCpy(char *dest,const char *src,size_t n);
+char *strncpyn(char *dest, const char *src,size_t n, char c);
+size_t strhex_to_str(char *p, size_t len, const char *strhex);
BOOL in_list(char *s,char *list,BOOL casesensitive);
-BOOL string_init(char **dest,char *src);
+BOOL string_init(char **dest,const char *src);
void string_free(char **s);
-BOOL string_set(char **dest,char *src);
-BOOL string_sub(char *s,char *pattern,char *insert);
+BOOL string_set(char **dest,const char *src);
+BOOL string_sub(char *s,const char *pattern,const char *insert);
void split_at_last_component(char *path, char *front, char sep, char *back);
/*The following definitions come from lib/util_unistr.c */
@@ -1266,8 +1270,8 @@ struct sam_disp_info *pwdb_sam_to_dispinfo(struct sam_passwd *user);
struct smb_passwd *pwdb_sam_to_smb(struct sam_passwd *user);
struct sam_passwd *pwdb_smb_to_sam(struct smb_passwd *user);
char *pwdb_encode_acct_ctrl(uint16 acct_ctrl, size_t length);
-uint16 pwdb_decode_acct_ctrl(char *p);
-time_t pwdb_get_last_set_time(char *p);
+uint16 pwdb_decode_acct_ctrl(const char *p);
+time_t pwdb_get_last_set_time(const char *p);
void pwdb_set_logon_time(char *p, int max_len, time_t t);
void pwdb_set_logoff_time(char *p, int max_len, time_t t);
void pwdb_set_kickoff_time(char *p, int max_len, time_t t);