diff options
author | Luke Leighton <lkcl@samba.org> | 1997-10-04 16:51:43 +0000 |
---|---|---|
committer | Luke Leighton <lkcl@samba.org> | 1997-10-04 16:51:43 +0000 |
commit | 07cc8fd8e8edd58110800f3b6b7aaec94687b579 (patch) | |
tree | 3a84c01129db95ba31803aebf9552840df5248fa /source3/include | |
parent | a193401384a0e861c1857d256963c9178644c301 (diff) | |
download | samba-07cc8fd8e8edd58110800f3b6b7aaec94687b579.tar.gz samba-07cc8fd8e8edd58110800f3b6b7aaec94687b579.tar.bz2 samba-07cc8fd8e8edd58110800f3b6b7aaec94687b579.zip |
proto.h:
- recreated, as usual.
smb.h:
- added RPC_HDR structure - the 18 byte MSRPC header
smbparse.c:
- added smb_io_rpc_hdr() function to read/write the RPC_HDR structure.
util.c:
- added align2, align4, align_offset functions.
- added skip_unicode_string, unistrcpy, unistrncpy functions.
- modified unistrcpy and unistrncpy to return the number of unicode
characters returned, effectively making skip_unicode_string redundant.
(This used to be commit b0ad811cda3dcffed5b24104229813cdb17b014f)
Diffstat (limited to 'source3/include')
-rw-r--r-- | source3/include/proto.h | 11 | ||||
-rw-r--r-- | source3/include/smb.h | 8 |
2 files changed, 16 insertions, 3 deletions
diff --git a/source3/include/proto.h b/source3/include/proto.h index 8818b9b527..4ec4a42f2a 100644 --- a/source3/include/proto.h +++ b/source3/include/proto.h @@ -565,7 +565,9 @@ void sync_browse_lists(struct subnet_record *d, struct work_record *work, /*The following definitions come from params.c */ -BOOL pm_process(char *pszFileName,BOOL (*sfunc)(char *),BOOL (*pfunc)(char *,char *)); +BOOL pm_process( char *FileName, + BOOL (*sfunc)(char *), + BOOL (*pfunc)(char *, char *) ); /*The following definitions come from password.c */ @@ -986,5 +988,12 @@ void file_unlock(int fd); BOOL is_myname(char *s); void set_remote_arch(enum remote_arch_types type); enum remote_arch_types get_remote_arch(); +char *skip_unicode_string(char *buf,int n); +char *unistr(char *buf); +int unistrncpy(char *dst, char *src, int len); +int unistrcpy(char *dst, char *src); void fstrcpy(char *dest, char *src); void pstrcpy(char *dest, char *src); +char *align4(char *q, char *base); +char *align2(char *q, char *base); +char *align_offset(char *q, char *base, int align_offset); diff --git a/source3/include/smb.h b/source3/include/smb.h index 37474436ca..b999c13667 100644 --- a/source3/include/smb.h +++ b/source3/include/smb.h @@ -80,6 +80,10 @@ typedef short int16; typedef int int32; #endif +#ifndef uint8 +typedef unsigned char uint8; +#endif + #ifndef uint16 typedef unsigned short uint16; #endif @@ -416,7 +420,7 @@ typedef struct gid_info } DOM_GID; -/* RPC_HEADER - ms rpc header */ +/* RPC_HDR - ms rpc header */ typedef struct rpc_hdr_info { uint8 major; /* 5 - RPC major version */ @@ -431,7 +435,7 @@ typedef struct rpc_hdr_info uint16 context_id; /* 0 - presentation context identifier */ uint8 cancel_count; /* 0 - cancel count */ uint8 reserved; /* 0 - reserved */ -} RPC_HEADER; +} RPC_HDR; struct smb_passwd { |